fr_mvvm_locale 1.0.0 copy "fr_mvvm_locale: ^1.0.0" to clipboard
fr_mvvm_locale: ^1.0.0 copied to clipboard

FlowR-MVVM: Locale

FlowR-MVVM: Locale

Features #

  • LocaleX
  • ILocaleViewModel, FrLocaleViewModel
  • FrLocaleSwitchView

Getting started #

Usage #

to /example folder.

class YourEnvViewModel extends FrLocaleViewModel {
  YourEnvViewModel({
    super.initValue = const Locale('en'),
    super.all = const [Locale('en'), Locale('zh'), Locale('zh')],
  });
}

void main() {
  runApp(
    FrProvider(
          (context) => YourEnvViewModel(),
      child: const MaterialApp(
        home: Scaffold(
          body: Center(child: FrLocaleSwitchView<YourEnvViewModel>()),
        ),
      ),
    ),
  );
}

Additional information #