Models
The models which has been provided with the templates.
User Model
The UserModel represents the data structure for user information in the application.
Properties
username (String): The username of the user.
email (String): The email address of the user.
password (String): The hashed password of the user.
authToken (String): The authentication token associated with the user.
Methods
fromJson(Map<String, dynamic> json) -> UserModel
fromJson(Map<String, dynamic> json) -> UserModelCreates a UserModel instance from a JSON map.
toJson() -> Map<String, dynamic>
toJson() -> Map<String, dynamic>Converts the UserModel instance to a JSON map.
copyWith({String? username, String? email, String? password, String? authToken}) -> UserModel
copyWith({String? username, String? email, String? password, String? authToken}) -> UserModelCreates a copy of the UserModel with optional modified properties.
Last updated
Was this helpful?