Skip to content

Instantly share code, notes, and snippets.

@piratefsh
Last active November 25, 2023 18:37
Show Gist options
  • Star 5 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save piratefsh/7607b6c166259a50b486c428712e3e69 to your computer and use it in GitHub Desktop.
Save piratefsh/7607b6c166259a50b486c428712e3e69 to your computer and use it in GitHub Desktop.

##Sublime linter setup Displays warnings and errors from ESLint. You need eslint installed. See readme of https://github.com/roadhump/SublimeLinter-eslint for eslint installation instructions

  1. With Package Manager, install SublimeLinter and SublimeLinter-contrib-eslint
  2. Cmd+Shift+P should now have a SublimeLinter: Lint This View option
  3. Running that should lint your file. It should also run the linter on file load and save (configurable on SublimeLinter settings)

##Sublime formatter setup Autoformats your files according to ESLint --fix option

  1. With Package Manager, install ESLint Formatter
  2. Cmd+Shift+P should have a ESLint Formatter: Format this file option
  3. Set config to use .eslintrc file and you can choose to format on save.
{
  "config_path": ".eslintrc",
  "format_on_save": false,
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment