mirror of
https://github.com/danny-avila/LibreChat.git
synced 2025-09-21 21:50:49 +02:00
🔄 chore: Enforce 18next Language Keys (#5803)
* chore: enforcing language keys to adhere to the new standard. * chore: enforcing i18n forbids to write plain text in JSX markup * chore: enforcing i18n forbids to write plain text in JSX markup * fix: ci with checkbox for unused keys :) * refactor: removed all the unused `i18n` keys
This commit is contained in:
parent
2a506df443
commit
7f48030452
33 changed files with 200 additions and 219 deletions
|
@ -8,6 +8,7 @@ import tsParser from '@typescript-eslint/parser';
|
|||
import importPlugin from 'eslint-plugin-import';
|
||||
import { FlatCompat } from '@eslint/eslintrc';
|
||||
import jsxA11Y from 'eslint-plugin-jsx-a11y';
|
||||
import i18next from 'eslint-plugin-i18next';
|
||||
import react from 'eslint-plugin-react';
|
||||
import jest from 'eslint-plugin-jest';
|
||||
import globals from 'globals';
|
||||
|
@ -58,6 +59,7 @@ export default [
|
|||
import: importPlugin,
|
||||
'jsx-a11y': fixupPluginRules(jsxA11Y),
|
||||
'import/parsers': tsParser,
|
||||
i18next,
|
||||
// perfectionist,
|
||||
},
|
||||
|
||||
|
@ -284,6 +286,13 @@ export default [
|
|||
},
|
||||
},
|
||||
rules: {
|
||||
// i18n
|
||||
'i18next/no-literal-string': [
|
||||
'error', {
|
||||
mode: 'jsx-text-only',
|
||||
'should-validate-template': true,
|
||||
}],
|
||||
//
|
||||
'@typescript-eslint/no-unused-expressions': 'off',
|
||||
'@typescript-eslint/no-unused-vars': 'off',
|
||||
'@typescript-eslint/no-explicit-any': 'off',
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue