Created
September 7, 2022 10:55
-
-
Save aunpyz/979a0070196e9808d5fbccab1bc7fa18 to your computer and use it in GitHub Desktop.
This file contains 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
//from | |
//class Person { | |
// final String name; | |
// final int age; | |
// | |
// Person({ | |
// required this.name, | |
// required this.age, | |
// }) | |
//} | |
//to | |
@freezed | |
class Person { | |
const factory Person({ | |
required String name, | |
required int age, | |
}) = _Person; | |
} |
This file contains 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
#!/bin/sh | |
cd /path/to/flutter/project | |
cd lib/ | |
flutter pub run build_runner build --delete-conflicting-outputs | |
# edit code to L:13-19 | |
flutter pub run build_runner build --delete-conflicting-outputs | |
# see the terminal, put something there in dart file | |
flutter pub run build_runner build --delete-conflicting-outputs | |
# copy-paste |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment