horizon/package.json
Michael Krotscheck c6c0352982 Switched from JSCS to ESLint
This patch switches horizon from using JSCS to using ESlint. It
adds the john papa style guides as an eslint plugin, and deactivates
additional linting rules so current cleanup efforts can focus on the
issues remaining from JSCS. Once that cleanup effort is complete,
we can switch our linting job to voting and move forward from there.

YAML for .eslintrc was chosen because the JSON specification does
not allow comments, and having comments (including rule links) will
make it easier to discuss linting changes.

Deactivated eslint rules have each been annotated with a # TODO
statement, so we can address them in the future. Links in the
documentation have been updated to new contributor guidelines, which
will be updated after this patch lands.

Linting may be executed by first installing npm dependencies using
`npm install`, and then executing `npm run lint` at any time in the
future. No python venv is required.

For clarification: We are switching to ESLint because JSCS explicitly
focuses on code-style, not on language use errors. For that purpose,
JSCS explicitly defers to JSHint, which due to the 'do no evil' license is
not usable. Since ESLint provides both the codestyle functionality, and
the language use checks, of both JSCS and JSHint, it was deemed the
only viable tool,

http://lists.openstack.org/pipermail/openstack-dev/2015-June/067030.html

Change-Id: Ib4c3f77f8cc3cdaa3c7558b7bc3a6d1299b6dcbe
Partially-Implements: blueprint jscs-cleanup
2015-06-30 23:00:29 -07:00

28 lines
857 B
JSON

{
"version": "0.0.0",
"private": true,
"name": "horizon",
"description": "OpenStack Horizon - Angular",
"repository": "none",
"license": "Apache 2.0",
"devDependencies": {
"eslint": "^0.23.0",
"eslint-plugin-angular": "0.0.10",
"jasmine-core": "2.2.0",
"karma": "0.12.31",
"karma-chrome-launcher": "0.1.8",
"karma-cli": "0.0.4",
"karma-coverage": "0.3.1",
"karma-jasmine": "0.3.5",
"karma-ng-html2js-preprocessor": "0.1.2",
"karma-phantomjs-launcher": "0.2.0",
"phantomjs": "1.9.17"
},
"scripts": {
"postinstall": "if [ ! -d .venv ]; then tox -epy27 --notest; fi",
"test": "karma start horizon/karma.conf.js --single-run && karma start openstack_dashboard/karma.conf.js --single-run",
"lint": "eslint --no-color horizon/static openstack_dashboard/static"
},
"dependencies": {}
}