Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to avoid lint problem "Depend on referenced packages" for gen_l10n/app_localizations.dart [closed]

Tags:

lint

flutter

dart

On my Flutter app, I've got this problem with lint rule : depend_on_referenced_packages

enter image description here

This file is generated here

enter image description here

Do you have any idea how to solve this without passing by ignore 'depend_on_referenced_packages' ?

in my pubspec.yaml, I only have this :

enter image description here

Thanks a lot

like image 812
NonowPoney Avatar asked Sep 01 '25 11:09

NonowPoney


1 Answers

Just add the package explicitly.

  1. run flutter pub add flutter_gen
  2. run flutter pub get

For more info, see https://dart-lang.github.io/linter/lints/depend_on_referenced_packages.html

like image 158
Yusuke Hakamaya Avatar answered Sep 04 '25 06:09

Yusuke Hakamaya