-
Notifications
You must be signed in to change notification settings - Fork 397
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Ignore implicit_dynamic_parameter in generated code #604
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I want to approve this, but we are really blocked on dart-lang/source_gen#370
This would also handle having to add all of the bits to each generator
Please 👍 dart-lang/source_gen#370
json_serializable/lib/src/utils.dart
Outdated
|
||
/// Comment to disable analysis errors not currently supported in generated | ||
/// output. Added to the top of all generated files. | ||
const ignoredWarningsComment = '// ignore_for_file: implicit_dynamic_parameter'; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Put this in json_serializable_generator
and make it private!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done
I don’t see it as a blocker. The ignore comment only gets added once in the file no matter how many classes you annotate in the file. That issue would improve the implementation, but tons of libraries add |
See #608 |
Done and looking for feedback on
implicit-dynamic: false
#557 by ignoring specific warning injson_serializable
generated codeexample
generated codeimplicit-dynamic: false
toexample
to demo, let me know if this should be removedNeed advisement