From 9d812e7242d50ea8b792edc7401dfdd8cf89ca54 Mon Sep 17 00:00:00 2001 From: AhsanRns Date: Tue, 7 May 2024 10:26:42 +0500 Subject: [PATCH] feat: easy localizations --- evently/lib/main.dart | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) diff --git a/evently/lib/main.dart b/evently/lib/main.dart index 01d470fbc0..e69a44e404 100644 --- a/evently/lib/main.dart +++ b/evently/lib/main.dart @@ -1,7 +1,21 @@ +import 'package:easy_localization/easy_localization.dart'; import 'package:flutter/material.dart'; void main() { - runApp(const MyApp()); + runApp( + EasyLocalization( + supportedLocales: const [ + Locale('en', 'US'), + Locale('ru', 'RU'), + Locale('es'), + Locale('de'), + ], + path: 'i18n', + fallbackLocale: const Locale('en', 'US'), + saveLocale: false, + child: const MyApp(), + ), + ); } class MyApp extends StatelessWidget {