Skip to content

feat: Add a lint to avoid hardcoded strings #153

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
2 tasks
ShahSomething opened this issue May 30, 2025 · 0 comments
Open
2 tasks

feat: Add a lint to avoid hardcoded strings #153

ShahSomething opened this issue May 30, 2025 · 0 comments
Labels
feature A new feature or request

Comments

@ShahSomething
Copy link

ShahSomething commented May 30, 2025

Description

It would be helpful to add a lint that flags hardcoded strings in Dart/Flutter code. Hardcoded strings can make localization and maintenance more difficult, especially in larger apps. A lint to detect these would help enforce best practices and encourage the use of constants, resource files, or localization frameworks like flutter_localizations.

Example

// Bad
Text('Welcome');

// Good
Text(AppStrings.welcome); 

Requirements

  • All CI/CD checks are passing.
  • There is no drop in the test coverage percentage.

Additional Context

No response

@ShahSomething ShahSomething added the feature A new feature or request label May 30, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature A new feature or request
Projects
None yet
Development

No branches or pull requests

1 participant