Skip to content

sgarbesi/javascript-eslint.tmbundle

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

20 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

JavaScript ESLint TextMate Bundle

Use the ESLint JavaScript validator in TextMate 2.

(Want to use JSHint instead? Try the jshint-external.tmbundle)

Screenshot 1

Features

  • Validate automatically when you save your file, and on-demand.
  • Shows you which .eslintrc settings are being used, with a direct link to open the applicable settings file.
  • Errors and warnings include a link to the relevant explanation on eslint.org.

Screenshot 2

Install

First install ESLint:

  1. Install Node.js.
  2. [sudo] npm install -g eslint

Now install the bundle:

  1. Download the latest release .zip file.
  2. Extract it and double-click to install in TextMate.

Release Notes

View the release notes.

Configuration

In most cases no configuration is required. However, in some cases you may want to customize the following:

  • Use eslint that is not on your PATH: If eslint is not on your PATH, set the TM_JAVASCRIPT_ESLINT_ESLINT variable to point to it. Set in TextMate > Preferences… > Variables.
  • Don’t validate on save: If you don’t want to validate your JavaScript automatically when you press ⌘S:
    1. Open the Bundle Editor (Bundles > Edit Bundles…).
    2. Navigate to JavaScript ESLint > Menu Actions > Save & Validate with ESLint.
    3. In the drawer that appears, delete the “Key Equivalent” of ⌘S.
  • Use a project-specific ESLint configuration:
    • eslint automatically uses .eslintrc files found in your directory tree. See the documentation on configuring ESLint for more information.

Uninstall

  1. Quit TextMate.
  2. Open ~/Library/Application Support/Avian/Pristine Copy/Bundles.
  3. Trash javascript-eslint.tmbundle.
  4. Open ~/Library/Application Support/Avian/Bundles.
  5. If there is a file called JavaScript ESLint.tmbundle, trash it.
  6. You may need to clear TextMate’s cache by trashing ~/Library/Caches/com.macromates.TextMate.preview.

About

Integrates the ESLint JavaScript validator with TextMate 2

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Python 89.2%
  • JavaScript 9.7%
  • Shell 1.1%