WikiEducationFoundation / WikiEduDashboard

Wiki Education Foundation's Wikipedia course dashboard system
https://dashboard.wikiedu.org
MIT License
385 stars 600 forks source link

Added new eslint rule to disallow string literals #5735

Closed prathamVaidya closed 3 months ago

prathamVaidya commented 3 months ago

What this PR does

This PR added a new ESLint rule to disallow string literals. This will help users to prefer I18n use over string literals to promote localization.

https://github.com/edvardchen/eslint-plugin-i18next

Screenshots

image

There are two modes for it:

Currently its set to jsx-only. Let me know if you want to change.

prathamVaidya commented 3 months ago

There are 306 places where string literals are directly used. I have updated the rule to only throw a warning. Fixing these can be a good-first-issue for beginners.

image