no-undef": 1,//不能有未定义的变量 "no-undef-init": 2,//变量初始化时不能直接给它赋值为undefined "no-undefined": 2,//不能使用undefined "no-unexpected-multiline
no-this-before-super': 'warn', //在构造函数中禁止在调用 super()之前使用 this 或 super 'no-undef': 'error', //禁用未声明的变量 'no-unexpected-multiline
error", 4], // 方法名和刮号之间不加空格 'space-before-function-paren': ['error', 'never'], "no-unexpected-multiline
大致如下: { "curly": "off", "no-unexpected-multiline": "off", "@babel/object-curly-spacing": "off",
no-undef”: 1,//不能有未定义的变量 “no-undef-init”: 2,//变量初始化时不能直接给它赋值为undefined “no-undefined”: 2,//不能使用undefined “no-unexpected-multiline
Math() JSON() 'no-regex-spaces': 1, //禁止正则表达式字面量中出现多个空格 'no-sparse-arrays': 1, //禁用稀疏数组 'no-unexpected-multiline
no-undef": 2,//不能有未定义的变量 "no-undef-init": 2,//变量初始化时不能直接给它赋值为undefined "no-undefined": 2,//不能使用undefined "no-unexpected-multiline
eslint: no-unexpected-multiline // ✓ ok ;(function () { window.alert('ok') }()) // ✗ avoid (function
'error' : 'off', 'no-unexpected-multiline': 'error', // 禁止空余的多行 'no-useless-escape': 'off', /
'error' : 'off', // 添加,分号必须 semi: ['error', 'always'], 'no-unexpected-multiline': 'off',
** eslint: no-unexpected-multiline ** // ✓ ok ;(function () { window.alert('ok') }()) // ✗ avoid (
no-undef": 1,//不能有未定义的变量 "no-undef-init": 2,//变量初始化时不能直接给它赋值为undefined "no-undefined": 2,//不能使用undefined "no-unexpected-multiline..., /** * 禁止出现难以理解的多行表达式 * @category Possible Errors */ 'no-unexpected-multiline
See: https://github.com/prettier/eslint-config-prettier#special-rules - no-unexpected-multiline 此时假设