Skip to content

Localizations #42

Answered by Daniel-Ioannou
tverra asked this question in Q&A
Discussion options

You must be logged in to vote

@tverra The package follows the official Flutter guide for localizations.
For each package that support localization the app must include the package's delegate in the list of the app delegates. So for country_picker package you have to add the CountryLocalizations.delegate in the list of your app delegates.

If you check the example from the Flutter docs, in this example the app import localizations for Material, Widgets, Cupertino and the app.

MaterialApp(
localizationsDelegates: [
  AppLocalizations.delegate,
  GlobalMaterialLocalizations.delegate,
  GlobalWidgetsLocalizations.delegate,
  GlobalCupertinoLocalizations.delegate,
],
supportedLocales: [
   const Locale('en', ''), // English…

Replies: 2 comments

Comment options

You must be logged in to vote
0 replies
Answer selected by Daniel-Ioannou
Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
documentation Improvements or additions to documentation
2 participants
Converted from issue

This discussion was converted from issue #22 on August 31, 2021 06:49.