Comments (8)
Ok, but the linter errors still exists. I could use super_enum now only by moving all enums to an extra folder where I can override the linter rules.
In this Github Repository I added linter tests for lint, package lint, effective dart and pedantic. All of them are failing. It would be nice, if you could add an
// ignore_for_file: return_of_invalid_type,constant_identifier_names, prefer_const_constructors_in_immutables, unnecessary_this, sort_unnamed_constructors_first, join_return_with_assignment
or fix the warnings.
from super_enum.
Okay, I'll soon look into this and fix this in the next release.
from super_enum.
@cfregin can you please mention the super_enum_generator
version you are using? Try upgrading to the latest v0.5.0
.
from super_enum.
I am using super_enum_generator: ^0.5.0
dev_dependencies:
lint: ^1.1.1
analysis_options.yaml
include: package:lint/analysis_options.yaml
from super_enum.
This shouldn't be a problem as we are following effective dart guidelines.
https://dart.dev/guides/language/effective-dart/design#avoid-using-futureort-as-a-return-type
from super_enum.
I'm facing the same issue. The lintner shows a bunch of errors in generated files.
from super_enum.
@cfregin, @klisiewicz I need to change the whole part builder
in order to add ignore rules in file headers, If this is urgent, you can create a build.yaml
file in your local project and add these lines for autogenerating it.
For example https://github.com/dart-lang/source_gen/blob/master/example_usage/build.yaml
targets:
$default:
builders:
source_gen|combining_builder:
options:
ignore_for_file:
- return_of_invalid_type
- constant_identifier_names
- prefer_const_constructors_in_immutables
- unnecessary_this
- sort_unnamed_constructors_first
- join_return_with_assignment
from super_enum.
Fixed in #59
from super_enum.
Related Issues (20)
- Enum as data field in another enum HOT 1
- DataFields with a name including 'T' break code generation HOT 1
- use const constructor
- @UseClass generating Error HOT 1
- Generate copyWith methods for data classes
- Create a separate whenAsync method for handling asynchronous calls and remove FutureOr from whenXXX.
- Generate whenPartial with normal return type HOT 2
- Why renaming enum fields? HOT 2
- Optional fields HOT 5
- emit `when` method arguments for "empty" actions HOT 2
- Use PartBuilder instead of SharedPartBuilder in generator
- Allow setting null value in copyWith function
- WhenPartial breaks when updraging from 0.3.0 to 0.4.2 HOT 2
- Can you please make a release? HOT 1
- Could we allow to generate some types as private types to be consumed by the bloc itself only?
- super_enum is not working with analyzer ^0.40.1 HOT 2
- Overriding == operator of Data classes
- How can I convert a String to a Enum Type
- Release null safe version ? HOT 15
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from super_enum.