easy_localization icon indicating copy to clipboard operation
easy_localization copied to clipboard

[Question] Path is not required when passing CodegenLoader

Open Yayo-Arellano opened this issue 3 years ago • 0 comments

In the next fragment of code, why should we pass the path if is not required given that we already generated the required code and we pass in the assetLoader.

Is there any way to remove the path in this case? I find it is confusing given that I do not even add the 'resources/langs' folder to the project.

import 'generated/codegen_loader.g.dart';
  ...
  void main(){
    runApp(EasyLocalization(
      child: MyApp(),
      supportedLocales: [Locale('en', 'US'), Locale('ar', 'DZ')],
      path: 'resources/langs',
      assetLoader: CodegenLoader()
    ));
  }
  ...

Yayo-Arellano avatar Apr 28 '21 03:04 Yayo-Arellano