localizely / flutter-intl-intellij

This Android Studio & IntelliJ plugin generates boilerplate code for localization of Flutter apps with official Dart Intl library
MIT License
129 stars 4 forks source link

generated different code #115

Closed jasoncfpl closed 10 months ago

jasoncfpl commented 10 months ago

This is the code difference: Generated by my collegue:

 'de': () => new SynchronousFuture(null),
  'en': () => new SynchronousFuture(null),
  'nl': () => new SynchronousFuture(null),

Generated by me:

  'de': () => new Future.value(null),
  'en': () => new Future.value(null),
  'nl': () => new Future.value(null),

we use the same plugin verison 2.18.4 i dont know why

lzoran commented 10 months ago

Hi @lynnscode,

Could you check if you have the same version of the intl_utils package activated globally?

flutter pub global list
jasoncfpl commented 10 months ago

Hi @lynnscode,

Could you check if you have the same version of the intl_utils package activated globally?

flutter pub global list

Yes, our intl_utils use difference version.

i hava resolved , thank u very muck

jasoncfpl commented 10 months ago

@lzoran why the intl_utils version use difference version , our flutter version and flutter_intl plugin version is same

lzoran commented 10 months ago

The Flutter Intl plugin, by default, globally activates intl_utils >=2.0.0 <3.0.0, or the version of intl_utils that is specified as a dependency (or dev dependency) in the pubspec.yaml file. That way, the Flutter Intl plugin can easily activate a compatible version of intl_utils or use the version specified by the user.