Socket
Socket
Sign inDemoInstall

eslint-plugin-i18next

Package Overview
Dependencies
Maintainers
1
Versions
51
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

eslint-plugin-i18next - npm Package Compare versions

Comparing version 2.2.0 to 2.3.0

9

CHANGELOG.md

@@ -5,2 +5,11 @@ # Changelog

## [2.3.0](https://github.com/edvardchen/eslint-plugin-i18next/compare/v2.2.0...v2.3.0) (2019-07-26)
### Features
* skip literal in SwitchCase statement ([d270343](https://github.com/edvardchen/eslint-plugin-i18next/commit/d270343)), closes [#2](https://github.com/edvardchen/eslint-plugin-i18next/issues/2)
## [2.2.0](https://github.com/edvardchen/eslint-plugin-i18next/compare/v2.1.1...v2.2.0) (2019-07-24)

@@ -7,0 +16,0 @@

16

lib/rules/no-literal-string.js

@@ -200,2 +200,6 @@ /**

'SwitchCase > Literal'(node) {
visited.add(node);
},
'Literal:exit'(node) {

@@ -278,3 +282,13 @@ // visited and passed linting

const popularCallee = ['dispatch', 'commit']; // vuex callee
const popularCallee = [
//
// ─── VUEX CALLEE ────────────────────────────────────────────────────────────────
//
'dispatch',
'commit',
// ────────────────────────────────────────────────────────────────────────────────
'includes',
'indexOf'
];
function generateCalleeWhitelists(option) {

@@ -281,0 +295,0 @@ const ignoreCallee = (option && option.ignoreCallee) || [];

2

package.json
{
"name": "eslint-plugin-i18next",
"version": "2.2.0",
"version": "2.3.0",
"description": "ESLint plugin for i18n",

@@ -5,0 +5,0 @@ "keywords": [

@@ -34,3 +34,6 @@ /**

{ code: "name === 'Android' || name === 'iOS'" },
{ code: "switch(a){ case 'a': break; default: break;}" },
{ code: 'import name from "hello";' },
{ code: 'a.indexOf("ios")' },
{ code: 'a.includes("ios")' },
{ code: 'export * from "hello_export_all";' },

@@ -63,2 +66,6 @@ { code: 'export { a } from "hello_export";' },

{ code: 'a + "b"', errors },
{
code: "switch(a){ case 'a': var a ='b'; break; default: break;}",
errors
},
{ code: 'export const a = "hello_string";', errors },

@@ -65,0 +72,0 @@ { code: 'const a = "foo";', errors },

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc