1 Star 0 Fork 0

shizhier/scratch-blocks-me

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
克隆/下载
.eslintrc 2.15 KB
一键复制 编辑 原始数据 按行查看 历史
Rachel Fenichel 提交于 2018-06-21 10:03 . Require spaces around infix ops
{
"rules": {
"curly": ["error", "multi-line"],
"eol-last": ["error"],
"indent": [
"error", 2, # Blockly/Google use 2-space indents
# Blockly/Google uses +4 space indents for line continuations.
{
"SwitchCase": 1,
"MemberExpression": 2,
"ObjectExpression": 1,
"FunctionDeclaration": {
"body": 1,
"parameters": 2
},
"FunctionExpression": {
"body": 1,
"parameters": 2
},
"CallExpression": {
"arguments": 2
},
# Ignore default rules for ternary expressions.
"ignoredNodes": ["ConditionalExpression"]
}
],
"linebreak-style": ["error", "unix"],
"max-len": ["error", 120, 4],
"no-trailing-spaces": ["error", { "skipBlankLines": true }],
"no-unused-vars": [
"error",
{
"args": "after-used",
# Ignore vars starting with an underscore.
"varsIgnorePattern": "^_",
# Ignore arguments starting with an underscore.
"argsIgnorePattern": "^_"
}
],
"no-use-before-define": ["error"],
"quotes": ["off"], # Blockly mixes single and double quotes
"semi": ["error", "always"],
"space-before-function-paren": ["error", "never"], # Blockly doesn't have space before function paren
"space-infix-ops": ["error"],
"strict": ["off"], # Blockly uses 'use strict' in files
"no-cond-assign": ["off"], # Blockly often uses cond-assignment in loops
"no-redeclare": ["off"], # Closure style allows redeclarations
"valid-jsdoc": ["error", {"requireReturn": false}],
"no-console": ["off"],
"no-constant-condition": ["off"]
},
"env": {
"browser": true
},
"globals": {
"Blockly": true, # Blockly global
"goog": true, # goog closure libraries/includes
},
"extends": "eslint:recommended"
}
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/shizhier/scratch-blocks-me.git
git@gitee.com:shizhier/scratch-blocks-me.git
shizhier
scratch-blocks-me
scratch-blocks-me
develop

搜索帮助