Solution: Serializing JSON Using json_serializable
Explore solutions to serializing JSON using json_serializable challenge.
We'll cover the following...
We'll cover the following...
Solutions
Great job on completing all the steps in the previous challenge! Feel free to compare your code solutions with the solutions below:
dependencies:...json_annotation: ^4.4.0dev_dependencies:...build_runner: ^2.1.7json_serializable: ^6.1.4
Challenge 1: Set up json_serializable
In the pubspec.yaml file, we add the json_annotation dependency, which will allow us to add annotations to our code.
Then, under the dev_dependencies ...