Skip to content

Instantly share code, notes, and snippets.

@scheffler
Created May 18, 2019 14:48
Show Gist options
  • Select an option

  • Save scheffler/b70d782a7d8c5c286b1f53960f4afb21 to your computer and use it in GitHub Desktop.

Select an option

Save scheffler/b70d782a7d8c5c286b1f53960f4afb21 to your computer and use it in GitHub Desktop.
VSCode config

Visual Studio Code Configuration Prefs

This is a collection of vscode configuration settings that I've found useful.

Plugins

  • ESLint - javascript linting
  • Prettier - opinionted code formatter
  • vscode-styled-components - this is growing on me
  • vscode-styled-components-snippets
  • Simple React Snippets

User Settings

The eslint and prettier settings are configured to make the two tools work together. Let eslint invoke prettier to take care of js and prettier can directly handle the other file types it knows about.

{
    "workbench.startupEditor": "newUntitledFile",
    "emmet.includeLanguages": "javascriptreact",
    "emmet.triggerExpansionOnTab": true,
    "editor.minimap.enabled": true,
    "editor.tabSize": 2,
    "files.autoSave": "onFocusChange",
    "[javascript]": {
        "editor.formatOnSave": false
    },
    "editor.formatOnSave": true,
    "eslint.autoFixOnSave": true,
    "eslint.alwaysShowStatus": true,
    "prettier.disableLanguages": [
        "js"
    ],
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment