Socket
Socket
Sign inDemoInstall

eslint-plugin-es

Package Overview
Dependencies
89
Maintainers
1
Versions
14
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 1.2.0 to 1.3.0

lib/rules/no-json-superset.js

2

lib/index.js

@@ -131,2 +131,3 @@ /**

"no-generators": require("./rules/no-generators"),
"no-json-superset": require("./rules/no-json-superset"),
"no-keyword-properties": require("./rules/no-keyword-properties"),

@@ -172,2 +173,3 @@ "no-malformed-template-literals": require("./rules/no-malformed-template-literals"),

"no-octal-numeric-literals": require("./rules/no-octal-numeric-literals"),
"no-optional-catch-binding": require("./rules/no-optional-catch-binding"),
"no-promise": require("./rules/no-promise"),

@@ -174,0 +176,0 @@ "no-property-shorthands": require("./rules/no-property-shorthands"),

2

lib/rules/no-accessor-properties.js

@@ -14,3 +14,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-accessor-properties.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-accessor-properties.html",
},

@@ -17,0 +17,0 @@ fixable: null,

@@ -16,3 +16,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-array-from.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-array-from.html",
},

@@ -19,0 +19,0 @@ fixable: null,

@@ -16,3 +16,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-array-of.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-array-of.html",
},

@@ -19,0 +19,0 @@ fixable: null,

@@ -14,3 +14,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-arrow-functions.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-arrow-functions.html",
},

@@ -17,0 +17,0 @@ fixable: "code",

@@ -14,3 +14,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-async-functions.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-async-functions.html",
},

@@ -17,0 +17,0 @@ fixable: null,

@@ -14,3 +14,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-async-iteration.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-async-iteration.html",
},

@@ -17,0 +17,0 @@ fixable: null,

@@ -16,3 +16,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-atomics.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-atomics.html",
},

@@ -19,0 +19,0 @@ fixable: null,

@@ -16,3 +16,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-binary-numeric-literals.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-binary-numeric-literals.html",
},

@@ -19,0 +19,0 @@ fixable: null,

@@ -14,3 +14,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-block-scoped-functions.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-block-scoped-functions.html",
},

@@ -17,0 +17,0 @@ fixable: null,

@@ -14,3 +14,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-block-scoped-variables.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-block-scoped-variables.html",
},

@@ -17,0 +17,0 @@ fixable: null,

@@ -14,3 +14,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-classes.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-classes.html",
},

@@ -17,0 +17,0 @@ fixable: null,

@@ -14,3 +14,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-computed-properties.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-computed-properties.html",
},

@@ -17,0 +17,0 @@ fixable: null,

@@ -14,3 +14,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-default-parameters.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-default-parameters.html",
},

@@ -17,0 +17,0 @@ fixable: null,

@@ -14,3 +14,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-destructuring.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-destructuring.html",
},

@@ -17,0 +17,0 @@ fixable: null,

@@ -14,3 +14,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-exponential-operators.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-exponential-operators.html",
},

@@ -17,0 +17,0 @@ fixable: null,

@@ -14,3 +14,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-for-of-loops.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-for-of-loops.html",
},

@@ -17,0 +17,0 @@ fixable: null,

@@ -14,3 +14,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-generators.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-generators.html",
},

@@ -17,0 +17,0 @@ fixable: null,

@@ -77,3 +77,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-keyword-properties.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-keyword-properties.html",
},

@@ -80,0 +80,0 @@ fixable: null,

@@ -15,3 +15,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-malformed-template-literals.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-malformed-template-literals.html",
},

@@ -18,0 +18,0 @@ fixable: null,

@@ -16,3 +16,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-map.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-map.html",
},

@@ -19,0 +19,0 @@ fixable: null,

@@ -16,3 +16,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-math-acosh.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-math-acosh.html",
},

@@ -19,0 +19,0 @@ fixable: null,

@@ -16,3 +16,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-math-asinh.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-math-asinh.html",
},

@@ -19,0 +19,0 @@ fixable: null,

@@ -16,3 +16,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-math-atanh.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-math-atanh.html",
},

@@ -19,0 +19,0 @@ fixable: null,

@@ -16,3 +16,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-math-cbrt.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-math-cbrt.html",
},

@@ -19,0 +19,0 @@ fixable: null,

@@ -16,3 +16,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-math-clz32.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-math-clz32.html",
},

@@ -19,0 +19,0 @@ fixable: null,

@@ -16,3 +16,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-math-cosh.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-math-cosh.html",
},

@@ -19,0 +19,0 @@ fixable: null,

@@ -16,3 +16,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-math-expm1.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-math-expm1.html",
},

@@ -19,0 +19,0 @@ fixable: null,

@@ -16,3 +16,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-math-fround.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-math-fround.html",
},

@@ -19,0 +19,0 @@ fixable: null,

@@ -16,3 +16,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-math-hypot.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-math-hypot.html",
},

@@ -19,0 +19,0 @@ fixable: null,

@@ -16,3 +16,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-math-imul.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-math-imul.html",
},

@@ -19,0 +19,0 @@ fixable: null,

@@ -16,3 +16,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-math-log10.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-math-log10.html",
},

@@ -19,0 +19,0 @@ fixable: null,

@@ -16,3 +16,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-math-log1p.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-math-log1p.html",
},

@@ -19,0 +19,0 @@ fixable: null,

@@ -16,3 +16,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-math-log2.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-math-log2.html",
},

@@ -19,0 +19,0 @@ fixable: null,

@@ -16,3 +16,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-math-sign.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-math-sign.html",
},

@@ -19,0 +19,0 @@ fixable: null,

@@ -16,3 +16,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-math-sinh.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-math-sinh.html",
},

@@ -19,0 +19,0 @@ fixable: null,

@@ -16,3 +16,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-math-tanh.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-math-tanh.html",
},

@@ -19,0 +19,0 @@ fixable: null,

@@ -16,3 +16,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-math-trunc.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-math-trunc.html",
},

@@ -19,0 +19,0 @@ fixable: null,

@@ -14,3 +14,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-modules.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-modules.html",
},

@@ -17,0 +17,0 @@ fixable: null,

@@ -14,3 +14,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-new-target.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-new-target.html",
},

@@ -17,0 +17,0 @@ fixable: null,

@@ -16,3 +16,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-number-epsilon.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-number-epsilon.html",
},

@@ -19,0 +19,0 @@ fixable: null,

@@ -16,3 +16,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-number-isfinite.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-number-isfinite.html",
},

@@ -19,0 +19,0 @@ fixable: null,

@@ -16,3 +16,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-number-isinteger.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-number-isinteger.html",
},

@@ -19,0 +19,0 @@ fixable: null,

@@ -16,3 +16,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-number-isnan.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-number-isnan.html",
},

@@ -19,0 +19,0 @@ fixable: null,

@@ -16,3 +16,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-number-issafeinteger.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-number-issafeinteger.html",
},

@@ -19,0 +19,0 @@ fixable: null,

@@ -16,3 +16,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-number-maxsafeinteger.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-number-maxsafeinteger.html",
},

@@ -19,0 +19,0 @@ fixable: null,

@@ -16,3 +16,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-number-minsafeinteger.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-number-minsafeinteger.html",
},

@@ -19,0 +19,0 @@ fixable: null,

@@ -16,3 +16,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-number-parsefloat.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-number-parsefloat.html",
},

@@ -19,0 +19,0 @@ fixable: null,

@@ -16,3 +16,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-number-parseint.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-number-parseint.html",
},

@@ -19,0 +19,0 @@ fixable: null,

@@ -16,3 +16,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-object-assign.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-object-assign.html",
},

@@ -19,0 +19,0 @@ fixable: null,

@@ -16,3 +16,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-object-entries.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-object-entries.html",
},

@@ -19,0 +19,0 @@ fixable: null,

@@ -17,3 +17,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-object-getownpropertydescriptors.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-object-getownpropertydescriptors.html",
},

@@ -20,0 +20,0 @@ fixable: null,

@@ -16,3 +16,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-object-getownpropertysymbols.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-object-getownpropertysymbols.html",
},

@@ -19,0 +19,0 @@ fixable: null,

@@ -16,3 +16,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-object-is.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-object-is.html",
},

@@ -19,0 +19,0 @@ fixable: null,

@@ -16,3 +16,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-object-setprototypeof.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-object-setprototypeof.html",
},

@@ -19,0 +19,0 @@ fixable: null,

@@ -15,3 +15,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-object-super-properties.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-object-super-properties.html",
},

@@ -18,0 +18,0 @@ fixable: null,

@@ -16,3 +16,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-object-values.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-object-values.html",
},

@@ -19,0 +19,0 @@ fixable: null,

@@ -16,3 +16,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-octal-numeric-literals.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-octal-numeric-literals.html",
},

@@ -19,0 +19,0 @@ fixable: null,

@@ -16,3 +16,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-promise.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-promise.html",
},

@@ -19,0 +19,0 @@ fixable: null,

@@ -14,3 +14,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-property-shorthands.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-property-shorthands.html",
},

@@ -17,0 +17,0 @@ fixable: null,

@@ -16,3 +16,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-proxy.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-proxy.html",
},

@@ -19,0 +19,0 @@ fixable: null,

@@ -16,3 +16,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-reflect.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-reflect.html",
},

@@ -19,0 +19,0 @@ fixable: null,

@@ -17,3 +17,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-regexp-lookbehind-assertions.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-regexp-lookbehind-assertions.html",
},

@@ -20,0 +20,0 @@ fixable: null,

@@ -17,3 +17,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-regexp-named-capture-groups.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-regexp-named-capture-groups.html",
},

@@ -20,0 +20,0 @@ fixable: null,

@@ -16,3 +16,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-regexp-s-flag.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-regexp-s-flag.html",
},

@@ -19,0 +19,0 @@ fixable: null,

@@ -16,3 +16,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-regexp-u-flag.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-regexp-u-flag.html",
},

@@ -19,0 +19,0 @@ fixable: null,

@@ -17,3 +17,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-regexp-unicode-property-escapes.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-regexp-unicode-property-escapes.html",
},

@@ -20,0 +20,0 @@ fixable: null,

@@ -16,3 +16,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-regexp-y-flag.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-regexp-y-flag.html",
},

@@ -19,0 +19,0 @@ fixable: null,

@@ -14,3 +14,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-rest-parameters.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-rest-parameters.html",
},

@@ -17,0 +17,0 @@ fixable: null,

@@ -14,3 +14,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-rest-spread-properties.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-rest-spread-properties.html",
},

@@ -17,0 +17,0 @@ fixable: null,

@@ -16,3 +16,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-set.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-set.html",
},

@@ -19,0 +19,0 @@ fixable: null,

@@ -16,3 +16,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-shared-array-buffer.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-shared-array-buffer.html",
},

@@ -19,0 +19,0 @@ fixable: null,

@@ -14,3 +14,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-spread-elements.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-spread-elements.html",
},

@@ -17,0 +17,0 @@ fixable: null,

@@ -16,3 +16,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-string-fromcodepoint.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-string-fromcodepoint.html",
},

@@ -19,0 +19,0 @@ fixable: null,

@@ -16,3 +16,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-string-raw.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-string-raw.html",
},

@@ -19,0 +19,0 @@ fixable: null,

@@ -16,3 +16,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-subclassing-builtins.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-subclassing-builtins.html",
},

@@ -19,0 +19,0 @@ fixable: null,

@@ -16,3 +16,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-symbol.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-symbol.html",
},

@@ -19,0 +19,0 @@ fixable: null,

@@ -52,3 +52,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-template-literals.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-template-literals.html",
},

@@ -55,0 +55,0 @@ fixable: "code",

@@ -16,3 +16,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-trailing-commas.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-trailing-commas.html",
},

@@ -19,0 +19,0 @@ fixable: null,

@@ -17,3 +17,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-trailing-function-commas.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-trailing-function-commas.html",
},

@@ -20,0 +20,0 @@ fixable: null,

@@ -16,3 +16,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-typed-arrays.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-typed-arrays.html",
},

@@ -19,0 +19,0 @@ fixable: null,

@@ -28,3 +28,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-unicode-codepoint-escapes.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-unicode-codepoint-escapes.html",
},

@@ -49,3 +49,5 @@ fixable: "code",

for (const match of codePointEscapeSearchGenerator(text)) {
const range = [match.start + node.start, match.end + node.start]
const start = match.index
const end = start + match[0].length
const range = [start + node.start, end + node.start]
context.report({

@@ -59,6 +61,3 @@ node,

fix(fixer) {
const codePointStr = text.slice(
match.start + 3,
match.end - 1
)
const codePointStr = text.slice(start + 3, end - 1)
// https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String/fromCodePoint

@@ -75,3 +74,3 @@ let codePoint = Number(`0x${codePointStr}`)

const highSurrogate = (codePoint >> 10) + 0xd800
const lowSurrogate = codePoint % 0x400 + 0xdc00
const lowSurrogate = (codePoint % 0x400) + 0xdc00
replacement = `${toHex(highSurrogate)}\\u${toHex(

@@ -78,0 +77,0 @@ lowSurrogate

@@ -16,3 +16,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-weak-map.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-weak-map.html",
},

@@ -19,0 +19,0 @@ fixable: null,

@@ -16,3 +16,3 @@ /**

url:
"https://github.com/mysticatea/eslint-plugin-es/blob/v1.2.0/docs/rules/no-weak-set.md",
"http://mysticatea.github.io/eslint-plugin-es/rules/no-weak-set.html",
},

@@ -19,0 +19,0 @@ fixable: null,

@@ -10,2 +10,3 @@ /**

CONSTRUCT,
PatternMatcher,
ReferenceTracker,

@@ -15,38 +16,2 @@ getStringIfConstant,

/**
* Check whether a given character is escaped or not.
* @param {string} text The string to check.
* @param {number} index The location of the character to check.
* @returns {boolean} `true` if the character is escaped.
*/
function isEscaped(text, index) {
let escaped = false
for (let i = index - 1; i >= 0 && text.charCodeAt(i) === 0x5c; --i) {
escaped = !escaped
}
return escaped
}
/**
* Define generator to search pattern.
* The iterator generated by the generator returns the start and end index of the match.
* @param {RegExp} pattern Base pattern
* @returns {function} generator
*/
function definePatternSearchGenerator(pattern) {
return function*(text) {
let match = null
pattern.lastIndex = 0
while ((match = pattern.exec(text)) != null) {
if (!isEscaped(text, match.index)) {
yield {
start: match.index,
end: pattern.lastIndex,
}
}
}
}
}
module.exports = {

@@ -58,10 +23,21 @@ /**

* @param {RegExp} pattern The pattern to check. This must have `g` flag.
* @returns {function(string): boolean} The created predicate function.
* @returns {function(string):boolean} The created predicate function.
*/
definePatternMatcher(pattern) {
const gen = definePatternSearchGenerator(pattern)
return text => !gen(text).next().done
const matcher = new PatternMatcher(pattern)
return matcher.test.bind(matcher)
},
/**
* Define generator to search pattern.
* The iterator generated by the generator returns the start and end index of the match.
* @param {RegExp} pattern Base pattern
* @returns {function(string):IterableIterator<RegExpExecArray>} generator
*/
definePatternSearchGenerator(pattern) {
const matcher = new PatternMatcher(pattern)
return matcher.execAll.bind(matcher)
},
/**
* Check whether a given token is a comma token or not.

@@ -76,3 +52,2 @@ * @param {Token} token The token to check.

},
definePatternSearchGenerator,

@@ -79,0 +54,0 @@ /**

{
"name": "eslint-plugin-es",
"version": "1.2.0",
"version": "1.3.0",
"description": "ESLint plugin about ECMAScript syntactic features.",

@@ -13,21 +13,21 @@ "engines": {

"peerDependencies": {
"eslint": "^4.19.1 || >=5.0.0"
"eslint": ">=4.19.1"
},
"dependencies": {
"eslint-utils": "^1.1.0"
"eslint-utils": "^1.3.0"
},
"devDependencies": {
"codecov": "^3.0.0",
"eslint": "^4.19.1",
"eslint-config-mysticatea": "^13.0.2",
"eslint-config-prettier": "^2.9.0",
"eslint-plugin-eslint-plugin": "^1.4.0",
"eslint-plugin-prettier": "^2.6.0",
"@mysticatea/eslint-plugin": "^5.0.0",
"babel-eslint": "^8.2.3",
"codecov": "^3.0.2",
"eslint": "^5.0.1",
"eslint4b": "^5.0.0",
"globals": "^11.5.0",
"mocha": "^5.0.5",
"npm-run-all": "^4.1.2",
"nyc": "^11.6.0",
"nyc": "^11.8.0",
"opener": "^1.4.3",
"prettier": "^1.11.1",
"rimraf": "^2.6.2"
"rimraf": "^2.6.2",
"vue-eslint-editor": "^0.1.0",
"vuepress": "github:mysticatea/vuepress#skip-waiting"
},

@@ -38,9 +38,11 @@ "scripts": {

"coverage": "nyc report -r lcov && opener ./coverage/lcov-report/index.html",
"lint": "eslint lib tests scripts .eslintrc.js --ignore-pattern !.eslintrc.js",
"docs:build": "vuepress build docs",
"docs:watch": "vuepress dev docs",
"lint": "eslint lib tests scripts",
"new": "node scripts/new-rule",
"pretest": "npm run -s lint",
"test": "nyc mocha tests/**/*.js --reporter dot",
"update": "run-s update:*",
"update:url": "npm run -s lint -- --fix",
"update:ruledocs": "node scripts/update-docs-rules",
"update:readme": "node scripts/update-readme",
"update:index": "node scripts/update-index",

@@ -47,0 +49,0 @@ "preversion": "npm test",

@@ -9,3 +9,3 @@ # eslint-plugin-es

ESLint plugin about ECMAScript syntactic features.
ESLint plugin which disallows each ECMAScript syntax.

@@ -20,167 +20,6 @@ ## 🏁 Goal

## 💿 Installation
Use [npm](https://www.npmjs.com/) or [yarn](https://yarnpkg.com/).
```console
npm install --save-dev eslint eslint-plugin-es
```
### Requirements
- Node.js `6.5.0` or newer.
- ESLint `4.19.1` or newer.
## 📖 Usage
Configure your `.eslintrc.*` file.
See [documentation](https://mysticatea.github.io/eslint-plugin-es/)
For example, to enable only Rest/Spread Properties in ES2018, as similar to legacy `experimentalObjectRestSpread` option:
```json
{
"plugins": ["es"],
"parserOptions": {
"ecmaVersion": 2018
},
"rules": {
"es/no-async-iteration": "error",
"es/no-malformed-template-literals": "error",
"es/no-regexp-lookbehind-assertions": "error",
"es/no-regexp-named-capture-groups": "error",
"es/no-regexp-s-flag": "error",
"es/no-regexp-unicode-property-escapes": "error"
}
}
```
### Configs
This plugin provides the following configs.
| Config ID | Description |
|:----------|:------------|
| `plugin:es/no-2018` | enable all ES2018 rules.
| `plugin:es/no-2017` | enable all ES2017 rules.
| `plugin:es/no-2016` | enable all ES2016 rules.
| `plugin:es/no-2015` | enable all ES2015 rules.
| `plugin:es/no-5` | enable all ES5 rules.
### Rules
This plugin provides the following rules.
- 🔧 mark means that the `--fix` option on the [command line](https://eslint.org/docs/user-guide/command-line-interface#fix) can automatically fix some of the problems reported by the rule.
<!--RULE_TABLE_BEGIN-->
#### ES2018
| Rule ID | Description | |
|:--------|:------------|:--:|
| [es/no-async-iteration](docs/rules/no-async-iteration.md) | disallow async iteration. | |
| [es/no-malformed-template-literals](docs/rules/no-malformed-template-literals.md) | disallow template literals with invalid escape sequences. | |
| [es/no-regexp-lookbehind-assertions](docs/rules/no-regexp-lookbehind-assertions.md) | disallow RegExp lookbehind assertions. | |
| [es/no-regexp-named-capture-groups](docs/rules/no-regexp-named-capture-groups.md) | disallow RegExp named capture groups. | |
| [es/no-regexp-s-flag](docs/rules/no-regexp-s-flag.md) | disallow RegExp `s` flag. | |
| [es/no-regexp-unicode-property-escapes](docs/rules/no-regexp-unicode-property-escapes.md) | disallow RegExp Unicode property escape sequences. | |
| [es/no-rest-spread-properties](docs/rules/no-rest-spread-properties.md) | disallow rest/spread properties. | |
#### ES2017
| Rule ID | Description | |
|:--------|:------------|:--:|
| [es/no-async-functions](docs/rules/no-async-functions.md) | disallow async function declarations. | |
| [es/no-atomics](docs/rules/no-atomics.md) | disallow the `Atomics` class. | |
| [es/no-object-entries](docs/rules/no-object-entries.md) | disallow the `Object.entries` method. | |
| [es/no-object-getownpropertydescriptors](docs/rules/no-object-getownpropertydescriptors.md) | disallow the `Object.getOwnPropertyDescriptors` method. | |
| [es/no-object-values](docs/rules/no-object-values.md) | disallow the `Object.values` method. | |
| [es/no-shared-array-buffer](docs/rules/no-shared-array-buffer.md) | disallow the `SharedArrayBuffer` class. | |
| [es/no-trailing-function-commas](docs/rules/no-trailing-function-commas.md) | disallow trailing commas in parameter/argument lists. | |
#### ES2016
| Rule ID | Description | |
|:--------|:------------|:--:|
| [es/no-exponential-operators](docs/rules/no-exponential-operators.md) | disallow exponential operators. | |
#### ES2015
| Rule ID | Description | |
|:--------|:------------|:--:|
| [es/no-array-from](docs/rules/no-array-from.md) | disallow the `Array.from` method. | |
| [es/no-array-of](docs/rules/no-array-of.md) | disallow the `Array.of` method. | |
| [es/no-arrow-functions](docs/rules/no-arrow-functions.md) | disallow arrow function expressions. | 🔧 |
| [es/no-binary-numeric-literals](docs/rules/no-binary-numeric-literals.md) | disallow binary numeric literals. | |
| [es/no-block-scoped-functions](docs/rules/no-block-scoped-functions.md) | disallow block-scoped function declarations. | |
| [es/no-block-scoped-variables](docs/rules/no-block-scoped-variables.md) | disallow block-scoped variable declarations. | |
| [es/no-classes](docs/rules/no-classes.md) | disallow class declarations. | |
| [es/no-computed-properties](docs/rules/no-computed-properties.md) | disallow computed properties. | |
| [es/no-default-parameters](docs/rules/no-default-parameters.md) | disallow default parameters. | |
| [es/no-destructuring](docs/rules/no-destructuring.md) | disallow destructuring. | |
| [es/no-for-of-loops](docs/rules/no-for-of-loops.md) | disallow `for-of` statements. | |
| [es/no-generators](docs/rules/no-generators.md) | disallow generator function declarations. | |
| [es/no-map](docs/rules/no-map.md) | disallow the `Map` class. | |
| [es/no-math-acosh](docs/rules/no-math-acosh.md) | disallow the `Math.acosh` method. | |
| [es/no-math-asinh](docs/rules/no-math-asinh.md) | disallow the `Math.asinh` method. | |
| [es/no-math-atanh](docs/rules/no-math-atanh.md) | disallow the `Math.atanh` method. | |
| [es/no-math-cbrt](docs/rules/no-math-cbrt.md) | disallow the `Math.cbrt` method. | |
| [es/no-math-clz32](docs/rules/no-math-clz32.md) | disallow the `Math.clz32` method. | |
| [es/no-math-cosh](docs/rules/no-math-cosh.md) | disallow the `Math.cosh` method. | |
| [es/no-math-expm1](docs/rules/no-math-expm1.md) | disallow the `Math.expm1` method. | |
| [es/no-math-fround](docs/rules/no-math-fround.md) | disallow the `Math.fround` method. | |
| [es/no-math-hypot](docs/rules/no-math-hypot.md) | disallow the `Math.hypot` method. | |
| [es/no-math-imul](docs/rules/no-math-imul.md) | disallow the `Math.imul` method. | |
| [es/no-math-log10](docs/rules/no-math-log10.md) | disallow the `Math.log10` method. | |
| [es/no-math-log1p](docs/rules/no-math-log1p.md) | disallow the `Math.log1p` method. | |
| [es/no-math-log2](docs/rules/no-math-log2.md) | disallow the `Math.log2` method. | |
| [es/no-math-sign](docs/rules/no-math-sign.md) | disallow the `Math.sign` method. | |
| [es/no-math-sinh](docs/rules/no-math-sinh.md) | disallow the `Math.sinh` method. | |
| [es/no-math-tanh](docs/rules/no-math-tanh.md) | disallow the `Math.tanh` method. | |
| [es/no-math-trunc](docs/rules/no-math-trunc.md) | disallow the `Math.trunc` method. | |
| [es/no-modules](docs/rules/no-modules.md) | disallow modules. | |
| [es/no-new-target](docs/rules/no-new-target.md) | disallow `new.target` meta property. | |
| [es/no-number-epsilon](docs/rules/no-number-epsilon.md) | disallow the `Number.EPSILON` property. | |
| [es/no-number-isfinite](docs/rules/no-number-isfinite.md) | disallow the `Number.isFinite` method. | |
| [es/no-number-isinteger](docs/rules/no-number-isinteger.md) | disallow the `Number.isInteger` method. | |
| [es/no-number-isnan](docs/rules/no-number-isnan.md) | disallow the `Number.isNaN` method. | |
| [es/no-number-issafeinteger](docs/rules/no-number-issafeinteger.md) | disallow the `Number.isSafeInteger` method. | |
| [es/no-number-maxsafeinteger](docs/rules/no-number-maxsafeinteger.md) | disallow the `Number.MAX_SAFE_INTEGER` property. | |
| [es/no-number-minsafeinteger](docs/rules/no-number-minsafeinteger.md) | disallow the `Number.MIN_SAFE_INTEGER` property. | |
| [es/no-number-parsefloat](docs/rules/no-number-parsefloat.md) | disallow the `Number.parseFloat` method. | |
| [es/no-number-parseint](docs/rules/no-number-parseint.md) | disallow the `Number.parseInt` method. | |
| [es/no-object-assign](docs/rules/no-object-assign.md) | disallow the `Object.assign` method. | |
| [es/no-object-getownpropertysymbols](docs/rules/no-object-getownpropertysymbols.md) | disallow the `Object.getOwnPropertySymbols` method. | |
| [es/no-object-is](docs/rules/no-object-is.md) | disallow the `Object.is` method. | |
| [es/no-object-setprototypeof](docs/rules/no-object-setprototypeof.md) | disallow the `Object.setPrototypeOf` method. | |
| [es/no-object-super-properties](docs/rules/no-object-super-properties.md) | disallow `super` property accesses in object literals. | |
| [es/no-octal-numeric-literals](docs/rules/no-octal-numeric-literals.md) | disallow octal numeric literals. | |
| [es/no-promise](docs/rules/no-promise.md) | disallow the `Promise` class. | |
| [es/no-property-shorthands](docs/rules/no-property-shorthands.md) | disallow property shorthands. | |
| [es/no-proxy](docs/rules/no-proxy.md) | disallow the `Proxy` class. | |
| [es/no-reflect](docs/rules/no-reflect.md) | disallow the `Reflect` class. | |
| [es/no-regexp-u-flag](docs/rules/no-regexp-u-flag.md) | disallow RegExp `u` flag. | |
| [es/no-regexp-y-flag](docs/rules/no-regexp-y-flag.md) | disallow RegExp `y` flag. | |
| [es/no-rest-parameters](docs/rules/no-rest-parameters.md) | disallow rest parameters. | |
| [es/no-set](docs/rules/no-set.md) | disallow the `Set` class. | |
| [es/no-spread-elements](docs/rules/no-spread-elements.md) | disallow spread elements. | |
| [es/no-string-fromcodepoint](docs/rules/no-string-fromcodepoint.md) | disallow the `String.fromCodePoint` method. | |
| [es/no-string-raw](docs/rules/no-string-raw.md) | disallow the `String.raw` method. | |
| [es/no-subclassing-builtins](docs/rules/no-subclassing-builtins.md) | disallow the subclassing of the built-in classes. | |
| [es/no-symbol](docs/rules/no-symbol.md) | disallow the `Symbol` class. | |
| [es/no-template-literals](docs/rules/no-template-literals.md) | disallow template literals. | 🔧 |
| [es/no-typed-arrays](docs/rules/no-typed-arrays.md) | disallow ES2015 typed arrays. | |
| [es/no-unicode-codepoint-escapes](docs/rules/no-unicode-codepoint-escapes.md) | disallow Unicode code point escape sequences. | 🔧 |
| [es/no-weak-map](docs/rules/no-weak-map.md) | disallow the `WeakMap` class. | |
| [es/no-weak-set](docs/rules/no-weak-set.md) | disallow the `WeakSet` class. | |
#### ES5
| Rule ID | Description | |
|:--------|:------------|:--:|
| [es/no-accessor-properties](docs/rules/no-accessor-properties.md) | disallow accessor properties. | |
| [es/no-keyword-properties](docs/rules/no-keyword-properties.md) | disallow reserved words as property names. | |
| [es/no-trailing-commas](docs/rules/no-trailing-commas.md) | disallow trailing commas in array/object literals. | |
<!--RULE_TABLE_END-->
## 🚥 Semantic Versioning Policy

@@ -205,2 +44,4 @@

- `npm run coverage` shows the coverage result of the last `npm test` command.
- `npm run docs:build` builds documentation.
- `npm run docs:watch` builds documentation on each file change.
- `npm run watch` runs tests on each file change.
SocketSocket SOC 2 Logo

Product

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

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc