selfprivacy.org.app/lib/config/localization.dart
NaiJi 2ac8e4366b Linting!
Co-authored-by: Inex Code <inex.code@selfprivacy.org>
2022-06-06 01:40:34 +03:00

21 lines
546 B
Dart

import 'package:easy_localization/easy_localization.dart';
import 'package:flutter/material.dart';
class Localization extends StatelessWidget {
const Localization({
final super.key,
this.child,
});
final Widget? child;
@override
Widget build(final BuildContext context) => EasyLocalization(
supportedLocales: const [Locale('ru'), Locale('en')],
path: 'assets/translations',
fallbackLocale: const Locale('en'),
saveLocale: false,
useOnlyLangCode: true,
child: child!,
);
}