File tree Expand file tree Collapse file tree 3 files changed +22
-2
lines changed Expand file tree Collapse file tree 3 files changed +22
-2
lines changed Original file line number Diff line number Diff line change @@ -16,6 +16,7 @@ module.exports = {
1616 // =======
1717
1818 // Best Practices
19+ "default-param-last" : "error" ,
1920 "no-caller" : "error" ,
2021 "no-eval" : "error" ,
2122 "no-extend-native" : "error" ,
@@ -43,6 +44,7 @@ module.exports = {
4344 "no-useless-concat" : "error" ,
4445 "no-void" : "error" ,
4546 "no-with" : "error" ,
47+ "prefer-regex-literals" : "error" ,
4648 radix : "error" ,
4749 "wrap-iife" : [ "error" , "any" ] ,
4850 // no-case-declarations
@@ -57,6 +59,7 @@ module.exports = {
5759 // Possible Errors
5860 "no-async-promise-executor" : "error" ,
5961 "no-extra-parens" : [ "error" , "functions" ] ,
62+ "no-import-assign" : "error" ,
6063 "require-atomic-updates" : "error" ,
6164 "valid-typeof" : [
6265 "error" ,
Original file line number Diff line number Diff line change @@ -13,8 +13,11 @@ describe("base", () => {
1313 "no-redeclare" ,
1414 "getter-return" ,
1515 "no-self-assign" ,
16+ "no-import-assign" ,
1617 "require-atomic-updates" ,
17- "no-async-promise-executor"
18+ "no-async-promise-executor" ,
19+ "default-param-last" ,
20+ "prefer-regex-literals"
1821 ] ,
1922 warnings : [ "no-useless-return" ]
2023 } ,
Original file line number Diff line number Diff line change 1+ import mod from './mod' ;
2+
13var foo = { } ;
24var foo = { } ;
35const obj = {
@@ -9,6 +11,18 @@ const obj = {
911
1012obj . a = obj . a ;
1113
14+ mod = 'mod' ;
15+ console . log ( mod ) ;
16+
1217( async ( ) => {
1318 obj . a += await new Promise ( async ( r ) => r ( 10 ) ) ;
14- } ) ( ) ;
19+ } ) ( ) ;
20+
21+ function fn ( a , b = 'b' , c ) {
22+ // noop
23+ }
24+ fn ( ) ;
25+
26+ const regexp = new RegExp ( 'foo|bar' ) ;
27+ console . log ( regexp ) ;
28+
You can’t perform that action at this time.
0 commit comments