Skip to content

Improve code quality, fixes #7 #8

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Aug 7, 2015
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .eslintignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
dist
coverage
node_modules
9 changes: 9 additions & 0 deletions .eslintrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
{
"extends": "eslint-config-airbnb-lite",
"env": {
"es6": true,
"mocha": true
},
"rules": {
}
}
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -26,4 +26,7 @@ build/Release
# https://www.npmjs.org/doc/misc/npm-faq.html#should-i-check-my-node_modules-folder-into-git
node_modules

# added automatically by precommit-hook as defaults
.jshint*

dist/
17 changes: 15 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,11 +11,20 @@
},
"devDependencies": {
"babel": "^5.8.20",
"babel-eslint": "^4.0.5",
"css-modules-loader-core": "0.0.12",
"eslint": "^1.0.0",
"eslint-config-airbnb": "0.0.7",
"eslint-config-airbnb-lite": "^1.0.3",
"eslint-watch": "^1.2.4",
"in-publish": "^2.0.0",
"mocha": "^2.2.5"
"mocha": "^2.2.5",
"precommit-hook": "^3.0.0"
},
"scripts": {
"start": "esw -w .",
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We can add here tests as well (in watch mode, using https://github.com/kimmobrunfeldt/concurrently)

"lint": "eslint .",
"pretest": "npm run -s lint || true",
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

|| true will be removed when code is fixed.

"test": "npm run -s build && mocha --compilers js:babel/register",
"build": "babel src --out-dir dist",
"prepublish": "in-publish && npm run -s build || in-install"
Expand All @@ -37,5 +46,9 @@
"bugs": {
"url": "https://github.com/sullenor/css-modules-require-hook/issues"
},
"homepage": "https://github.com/sullenor/css-modules-require-hook"
"homepage": "https://github.com/sullenor/css-modules-require-hook",
"pre-commit": [
"lint",
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This line should be removed later when code is fixed, since we already have pretest

"test"
]
}