prefer_shorthands 0.4.7 copy "prefer_shorthands: ^0.4.7" to clipboard
prefer_shorthands: ^0.4.7 copied to clipboard

An analyzer plugin that suggests using Dart's dot shorthand syntax.

0.4.7 #

  • Fix factory constructors with body return displayed warning that should not appeared. #21.

0.4.6 #

  • Adapt return Future #19.

0.4.5 #

  • Allow analyzer9.0.

0.4.4 #

  • Remove a output statements that may cause the analyze server to crash.
  • Adapt getter #16.
  • Adapt Record #15.
  • Enhance return type check for Iterable/Map/Record.

0.4.3 #

  • Adapt List and Set.
  • Adapt Map.
  • Adapt operator !=.
  • Add case DefaultFormalParameter (#8).
  • Fix case when assignment to dynamic, like <String, dynamic>{}..**['a'] = Foo.a** (#11).
  • Add case returnStatement and returnExpression (#9).
  • Fix case subtype_prefix_in_supertype_context (see test file).

0.4.2 #

  • Fix Size(100, 100) > Size.zero be wrong marning, the opearator > required righthand type is Size's Base Class, so here can't use shorthand. A similar situation is operator ??.
  • Fix bugDog(Animal.dog());, .dog is Animal's constructor, but function need a Dog, so here can't use shorthand.

0.4.1 #

0.4.0 #

  • Add more case.
  • Optimized code.
  • Improved testing.

0.3.3 #

  • Chore

0.3.2 #

  • Fix quick-fix case:
class Animal {
    static Dog dog => ...;
}
class Dog extends Animal{}

void main() {
    final animal = Animal.dog; // wrong quick-fix to `final Dog animal = .dog;`
}
  • The assignment behavior will now be correctly detected.

0.3.1 #

  • Support settings convert_implicit_declaration, defaults to false.

0.3.0+1 #

  • Fix.

0.3.0 #

  • Fix case borderRadius: BorderRadius.all(.circular(16)),

0.2.0 #

  • Fix case:
class Animal {}
class Dog extends Animal{
    static Dog husky() => ...;
}

void foo(Animal animal){}

void main() {
    foo(Dog.husky()); // should not warning
}

0.1.0+1 #

  • Update README.md.

0.1.0 #

  • Fix analyze argument list.

0.0.1+1 #

  • Fix.

0.0.1 #

  • Warning when not use dot shorthands!
3
likes
150
points
202
downloads

Publisher

verified publishernysm.dev

Weekly Downloads

An analyzer plugin that suggests using Dart's dot shorthand syntax.

Repository (GitHub)
View/report issues

Documentation

API reference

License

MIT (license)

Dependencies

analysis_server_plugin, analyzer, analyzer_plugin, meta, yaml

More

Packages that depend on prefer_shorthands