eslint-plugin-i18next
Advanced tools
Comparing version 1.0.3 to 1.0.4
@@ -128,5 +128,5 @@ /** | ||
function generateCalleeWhitelists(option) { | ||
const ignoreCallee = (option && option.ignoreCallee) || popularCallee; | ||
const ignoreCallee = (option && option.ignoreCallee) || []; | ||
const result = { | ||
simple: ['i18n', 'i18next'], | ||
simple: ['i18n', 'i18next', ...popularCallee], | ||
complex: ['i18n.t', 'i18next.t'] | ||
@@ -133,0 +133,0 @@ }; |
{ | ||
"name": "eslint-plugin-i18next", | ||
"version": "1.0.3", | ||
"version": "1.0.4", | ||
"description": "ESLint plugin for i18n", | ||
@@ -21,2 +21,4 @@ "keywords": [ | ||
"scripts": { | ||
"preversion": "npm run test", | ||
"postpublish": "git push --follow-tags", | ||
"test": "mocha tests --recursive" | ||
@@ -23,0 +25,0 @@ }, |
@@ -84,2 +84,15 @@ # eslint-plugin-i18next | ||
Maybe you use other internationalization libraries | ||
not [i18next](https://www.i18next.com/). You can use like this: | ||
```js | ||
/*eslint i18next/no-literal-string: ["error", { "ignoreCallee": ["yourI18n"] }]*/ | ||
const bar = yourI18n('bar'); | ||
// or | ||
/*eslint i18next/no-literal-string: ["error", { "ignoreCallee": ["yourI18n.method"] }]*/ | ||
const bar = yourI18n.method('bar'); | ||
``` | ||
#### Reudx/Vuex | ||
@@ -86,0 +99,0 @@ |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
12311
135