-
Notifications
You must be signed in to change notification settings - Fork 2k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add prettier and run prettier command via lint-staged (#448)
- Loading branch information
1 parent
c908a32
commit dbc954e
Showing
186 changed files
with
4,286 additions
and
1,432 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,41 +1,44 @@ | ||
module.exports = { | ||
env: { | ||
'browser': true, | ||
'node': true, | ||
}, | ||
extends: [ | ||
'eslint:recommended', | ||
'plugin:vue/recommended', | ||
], | ||
parserOptions: { | ||
parser: '@babel/eslint-parser', | ||
ecmaVersion: 2018, | ||
sourceType: 'module', | ||
requireConfigFile: false, | ||
}, | ||
rules: { | ||
'linebreak-style': ['error', 'unix'], | ||
semi: ['error', 'always'], | ||
quotes: ['error', 'single'], | ||
'comma-dangle': ['error', 'always-multiline'], | ||
'vue/require-v-for-key': 0, | ||
'vue/require-default-prop': 0, | ||
'vue/no-v-html': 0, | ||
'vue/max-attributes-per-line': 0, | ||
'vue/html-indent': ['error', 4], | ||
'vue/script-indent': ['error', 4, { | ||
baseIndent: 1, | ||
}], | ||
'vue/no-unused-vars': 0, | ||
'vue/html-self-closing': 0, | ||
'vue/multi-word-component-names': 0, | ||
'vue/no-reserved-component-names': 0, | ||
'eol-last': ['error', 'always'], | ||
}, | ||
globals: { | ||
'describe': true, | ||
'expect': true, | ||
'it': true, | ||
'test': true, | ||
}, | ||
env: { | ||
browser: true, | ||
node: true, | ||
}, | ||
extends: ['eslint:recommended', 'plugin:vue/recommended', 'prettier'], | ||
parserOptions: { | ||
parser: '@babel/eslint-parser', | ||
ecmaVersion: 2018, | ||
sourceType: 'module', | ||
requireConfigFile: false, | ||
}, | ||
rules: { | ||
'linebreak-style': ['error', 'unix'], | ||
semi: ['error', 'always'], | ||
'comma-dangle': ['error', 'always-multiline'], | ||
'vue/require-v-for-key': 0, | ||
'vue/require-default-prop': 0, | ||
'vue/no-v-html': 0, | ||
'vue/max-attributes-per-line': 0, | ||
'vue/html-indent': ['error', 4], | ||
'vue/script-indent': [ | ||
'error', | ||
4, | ||
{ | ||
baseIndent: 1, | ||
switchCase: 1, | ||
}, | ||
], | ||
'vue/no-unused-vars': 'warn', | ||
'vue/html-self-closing': 0, | ||
'vue/multi-word-component-names': 0, | ||
'vue/no-reserved-component-names': 0, | ||
'eol-last': ['error', 'always'], | ||
'prettier/prettier': 'error', | ||
}, | ||
globals: { | ||
describe: true, | ||
expect: true, | ||
it: true, | ||
test: true, | ||
}, | ||
plugins: ['prettier'], | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
{ | ||
"*.{js,vue}": [ | ||
"prettier --write", | ||
"eslint --quiet --cache --fix" | ||
], | ||
"*.scss": [ | ||
"stylelint --config node_modules/do-bulma/.stylelintrc.json --fix" | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
package.json | ||
package-lock.json |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
{ | ||
"singleQuote": true, | ||
"trailingComma": "all", | ||
"vueIndentScriptAndStyle": true, | ||
"htmlWhitespaceSensitivity": "ignore", | ||
"printWidth": 100, | ||
"tabWidth": 4, | ||
"singleAttributePerLine": true | ||
} |
Oops, something went wrong.
dbc954e
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This commit has been deployed to DigitalOcean Spaces for easy reviewing.