-
Notifications
You must be signed in to change notification settings - Fork 37
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Internal: Add prettier and simplify eslint config (#530)
* install prettier - create configuration file * install prettier config to prevent overlap with eslint styling * compress existing eslint files into a single * delete extraneous eslint files * add options - most are already default but nice to have explicit * lint the entire repo with prettier * wip before lint * test command * remove pug from eslint - odd * add pug commands - temp fix possibly * remove unused eslint pug plugin for eslint * lint and fix the pugs with prettier * lint again - these didnt get hit first time around
- Loading branch information
Showing
141 changed files
with
4,421 additions
and
2,754 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,7 +1,33 @@ | ||
{ | ||
"root": true, | ||
"extends": ["standard"], | ||
"rules": { | ||
"indent": ["error", 4] | ||
} | ||
} | ||
"root": true, | ||
"extends": ["standard", "plugin:prettier/recommended"], | ||
"plugins": ["prettier"], | ||
"rules": { | ||
"prettier/prettier": "error" | ||
}, | ||
"overrides": [ | ||
{ | ||
"files": ["src/frontend/**/*.js"], | ||
"env": { | ||
"browser": true, | ||
"es2020": true | ||
} | ||
}, | ||
{ | ||
"files": ["src/backend/**/*.js"], | ||
"env": { | ||
"node": true, | ||
"es2020": true | ||
} | ||
}, | ||
{ | ||
"files": ["tests/**/*.js"], | ||
"env": { | ||
"es2020": true, | ||
"node": true, | ||
"jest": true, | ||
"jasmine": true | ||
} | ||
} | ||
] | ||
} |
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,16 @@ | ||
# See https://prettier.io/docs/en/options. most are set to default | ||
trailingComma: "es5" | ||
tabWidth: 4 | ||
semi: false | ||
singleQuote: true | ||
bracketSpacing: true | ||
bracketSameLine: false | ||
arrowParens: always | ||
htmlWhitespaceSensitivity: strict | ||
singleAttributePerLine: false | ||
plugins: | ||
- "@prettier/plugin-pug" | ||
overrides: | ||
- files: "*.pug" | ||
options: | ||
parser: "pug" |
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 was deleted.
Oops, something went wrong.
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
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
Oops, something went wrong.