Registry / testing / eslint-plugin-i18n

eslint-plugin-i18n

JSON →
library2.4.0jsnpmunverified

ESLint plugin providing lint rules to prevent usage of non-Latin characters (Chinese, Greek, Japanese, Korean, Russian, Thai) in source code, helping enforce internationalization best practices. Current stable version is 2.4.0. Release cadence is irregular. Key differentiators: simple targeted rules for specific character sets, supports JSX, template literals, and configurable exclusions for identifiers, comments, function arguments, and module imports.

npm install eslint-plugin-i18n
INSTALL
IMPORT
SIG · ESLINT-PLUGIN-I18N
E
eslint-plugin-i18n
testingjavascriptv2.4.0
Install
—
Import
—
Disk
—
Pass rate
0/ 6
Env Coverage0 / 6
glibc
18–22
musl
18–22
Install & Compatibility
Where this runs
tested against v? · npm install
Install × environment matrix
Each cell = how many times install + import succeeded across repeated harness runs. Partial = flaky.
glibc = Debian/Ubuntu slim · musl = Alpine Linux
musl
node 18–226 runs
build_error
glibc
node 18–226 runs
build_error
Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

plugin
✓ plugins: ['i18n']
✗ plugins: ['eslint-plugin-i18n']
ESLint plugins are referenced without the 'eslint-plugin-' prefix.
rules
✓ "i18n/no-chinese-character": "error"
✗ "i18n/no-chinese-character": 2
Use severity strings ('error', 'warn', 'off') instead of numbers (deprecated in older ESLint).
rule config
✓ "i18n/no-chinese-character": ["error", { "excludeIdentifier": true }]
✗ "i18n/no-chinese-character": ["error", { "excludeIdentifiers": true }]
Option is 'excludeIdentifier' (singular), not 'excludeIdentifiers'. Check per-rule docs.

Shows how to install and configure eslint-plugin-i18n to prevent Chinese and Russian characters in source code.

// Install: npm install --save-dev eslint eslint-plugin-i18n // .eslintrc.json { "plugins": ["i18n"], "rules": { "i18n/no-chinese-character": "error", "i18n/no-russian-character": "warn" } } // test.js const greeting = '你好'; // ESLint will error: no-chinese-character
Debug
Known issues
breakingv2.0.0 dropped support for Node < 10
fix
Upgrade Node.js to version 10 or higher.
affects: <10
deprecatedUsing numeric severity (0,1,2) in ESLint rules is deprecated in ESLint >= 9
fix
Use string severity: 'off', 'warn', 'error'.
affects: >=1.0.0
gotchaRule options may differ between rules; check each rule's documentation for available options.
fix
Refer to docs/rules/<rule-name>.md for exact option names.
affects: >=2.0.0
Errors
Common errors & fixes
ESLint couldn't find the plugin "eslint-plugin-i18n".
Plugin not installed or missing from node_modules.
fix
Run 'npm install --save-dev eslint-plugin-i18n'.
Error: Failed to load plugin 'i18n': Cannot find module 'eslint-plugin-i18n'
Plugin not installed or ESLint can't resolve it.
fix
Ensure eslint-plugin-i18n is installed in the same project as ESLint.
Upgrade
Version history
2.4.0latest on npm
Audit
Dependencies

No dependency data recorded yet.

Agent activity
14 hits · last 30 days
node
12
Amazon
1
OpenAI (training)
1
Resources
eslint-plugin-i18n — npm install eslint-plugin-i18n · libregistry