diff --git a/pokedex/.vscode/launch.json b/pokedex/.vscode/launch.json new file mode 100644 index 0000000..6bfba97 --- /dev/null +++ b/pokedex/.vscode/launch.json @@ -0,0 +1,38 @@ +{ + // Use IntelliSense to learn about possible attributes. + // Hover to view descriptions of existing attributes. + // For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387 + "version": "0.2.0", + "configurations": [ + { + "name": "pokedex (debug mode)", + "request": "launch", + "type": "dart", + "flutterMode": "debug", + "program": "lib/app/main.dart", + "toolArgs": [ + "--enable-experiment=macros" + ] + }, + { + "name": "pokedex (profile mode)", + "request": "launch", + "type": "dart", + "flutterMode": "profile", + "program": "lib/app/main.dart", + "toolArgs": [ + "--enable-experiment=macros" + ] + }, + { + "name": "pokedex (release mode)", + "request": "launch", + "type": "dart", + "flutterMode": "release", + "program": "lib/app/main.dart", + "toolArgs": [ + "--enable-experiment=macros" + ] + } + ] +} \ No newline at end of file diff --git a/pokedex/analysis_options.yaml b/pokedex/analysis_options.yaml index fe275d2..dbbd620 100644 --- a/pokedex/analysis_options.yaml +++ b/pokedex/analysis_options.yaml @@ -19,4 +19,6 @@ linter: analyzer: exclude: - lib/**/*.g.dart - - lib/**/*.config.dart \ No newline at end of file + - lib/**/*.config.dart + enable-experiment: + - macros \ No newline at end of file diff --git a/pokedex/lib/pokemon_list/data/model/pokemon_list_response.dart b/pokedex/lib/pokemon_list/data/model/pokemon_list_response.dart new file mode 100644 index 0000000..2ac5459 --- /dev/null +++ b/pokedex/lib/pokemon_list/data/model/pokemon_list_response.dart @@ -0,0 +1,12 @@ +import 'package:json/json.dart'; + +@JsonCodable() +class PokemonListResponse { + PokemonListResponse({ + required this.name, + required this.url, + }); + + final String name; + final String url; +} diff --git a/pokedex/pubspec.yaml b/pokedex/pubspec.yaml index 515cfbd..c6a10a8 100644 --- a/pokedex/pubspec.yaml +++ b/pokedex/pubspec.yaml @@ -24,6 +24,7 @@ dependencies: shared_preferences: ^2.3.2 collection: ^1.18.0 dio: ^5.7.0 + json: ^0.20.2 dev_dependencies: flutter_test: