Skip to content

Instantly share code, notes, and snippets.

@babie
Last active May 25, 2018 16:58
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save babie/3a3441a3c2f866352d3a600eaf26ca6e to your computer and use it in GitHub Desktop.
Save babie/3a3441a3c2f866352d3a600eaf26ca6e to your computer and use it in GitHub Desktop.
tslint and prettier settings for vscode
// Place your settings in this file to overwrite the default settings
{
"javascript.validate.enable": false,
"files.autoSave": "afterDelay",
"files.autoSaveDelay": 1000,
"eslint.enable": true,
"eslint.autoFixOnSave": false,
"eslint.alwaysShowStatus": true,
"tslint.enable": true,
"tslint.autoFixOnSave": false,
"tslint.alwaysShowStatus": true,
"editor.formatOnSave": true,
"[json]": {
"editor.formatOnSave": false
},
"[javascript]": {
"editor.formatOnSave": false
},
"[javascriptreact]": {
"editor.formatOnSave": false
},
"[typescript]": {
"editor.formatOnSave": false
},
"[typescriptreact]": {
"editor.formatOnSave": false
},
"save-runner.enabled": true,
"save-runner.autoClearConsole": true,
"save-runner.commands": [
{
"enabled": true,
"include": "\\.jsx?$",
"exclude": "/node_modules/",
"isAsync": true,
"useTempFile": false,
"post": "yarn run eslint --fix ${relname}"
},
{
"enabled": true,
"include": "\\.tsx?$",
"exclude": "/node_modules/",
"isAsync": true,
"useTempFile": false,
"post": "yarn run tslint --project tsconfig.json --fix ${relname}"
},
{
"enabled": true,
"include": "\\.json$",
"exclude": "/node_modules/",
"isAsync": true,
"useTempFile": false,
"post": "yarn run prettier --write ${relname}"
}
]
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment