This package provides the following services:
linter-eslint
This linter plugin for Linter provides an interface to eslint. It will be used with files that have the “JavaScript” syntax.
Installation
apm install linter-eslint
linter-eslint will look for a version of eslint local to your project and
use it if it's available. If none is found it will fall back to the version it
ships with.
Lets say you depend on a specific version of eslint, maybe it has unreleased
features, maybe it's just newer than what linter-eslint ships with. If
your-project/node_modules/eslint exists linter-eslint will be used.
Note that if you do not have the linter package installed it will be installed
for you. If you are using an alternative linter-* consumer feel free to disable
the linter package.
Use with plugins
You have two options:
-
Install locally to your project
eslintand the plugin$ npm i --save-dev eslint [eslint-plugins]
-
Install globaly
eslintand plugins$ npm i -g eslint [eslint-plugins]- Activate
Use Global Eslintpackage option - (Optional) Set
Global Node Pathwith$ npm config get prefix
Settings
You can configure linter-eslint by editing ~/.atom/config.cson (choose Open Your Config in Atom menu) or in Preferences:
'linter-eslint':
'eslintRulesDir': 'mydir'
'disableWhenNoEslintrcFileInPath': true
'useGlobalEslint': true
'showRuleIdInMessage': true
'globalNodePath': '/Users/foo/.nvm/versions/io.js/v2.3.1'
eslintRulesDiris relative to the working directory (project root)disableWhenNoEslintrcFileInPathallows disabling linter-eslint when there is no.eslintrcfound in projectuseGlobalEslintallows using globally installed eslint and plugins for itshowRuleIdInMessagetruewill append theeslintruleId to warning/error messages
Contributing
If you would like to contribute enhancements or fixes, please do the following:
- Fork the plugin repository
- Hack on a separate topic branch created from the latest
master - Commit and push the topic branch
- Make a pull request
- Welcome to the club!
Please note that modifications should follow these coding guidelines:
- Indent is 2 spaces
- Code should pass
coffeelintlinter with the providedcoffeelint.json - Vertical whitespace helps readability, don’t be afraid to use it
Thank you for helping out!