Created
October 23, 2021 08:58
-
-
Save vaygeth89/2d709b40e270d8904984ce1348adf187 to your computer and use it in GitHub Desktop.
Serialized class
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| //Add this | |
| import 'package:json_annotation/json_annotation.dart'; | |
| //Add this | |
| part 'renew_access_token.g.dart'; | |
| //Add this | |
| @JsonSerializable() | |
| class RenewAccessToken { | |
| String refreshToken; | |
| RenewAccessToken({ | |
| required this.refreshToken, | |
| }); | |
| //Add this | |
| static RenewAccessToken fromJson(Map<String, dynamic> map) => | |
| _$RenewAccessTokenFromJson(map); | |
| Map<String, dynamic> toJson() => _$RenewAccessTokenToJson(this); | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment