Merge pull request from rschamp/Makefile--

Replace Makefile with npm scripts
This commit is contained in:
Ray Schamp 2016-10-18 09:44:44 -04:00 committed by GitHub
commit a484fda1a6
4 changed files with 15 additions and 32 deletions

5
.eslintignore Normal file
View file

@ -0,0 +1,5 @@
dist.js
node_modules/*
playground/*
render.js
render.min.js

View file

@ -1,26 +0,0 @@
ESLINT=./node_modules/.bin/eslint
WEBPACK=./node_modules/.bin/webpack --progress --colors
WEBPACK_DEV_SERVER=./node_modules/.bin/webpack-dev-server
# ------------------------------------------------------------------------------
build:
$(WEBPACK)
watch:
$(WEBPACK) --watch --watch-poll
serve:
$(WEBPACK_DEV_SERVER)
# ------------------------------------------------------------------------------
lint:
$(ESLINT) ./src/*.js
$(ESLINT) ./src/**/*.js
test:
@make lint
# ------------------------------------------------------------------------------
.PHONY: build watch serve lint test

View file

@ -50,7 +50,7 @@ renderer.connectWorker(worker);
## Standalone Build
```bash
make build
npm run build
```
```html
@ -63,7 +63,7 @@ make build
## Testing
```bash
make test
npm test
```
## Donate

View file

@ -11,10 +11,14 @@
},
"main": "./dist.js",
"scripts": {
"prepublish": "make build",
"start": "make serve",
"test": "make test",
"version": "./node_modules/.bin/json -f package.json -I -e \"this.repository.sha = '$(git log -n1 --pretty=format:%H)'\""
"build": "./node_modules/.bin/webpack --progress --colors",
"lint": "./node_modules/.bin/eslint .",
"prepublish": "npm run build",
"prepublish-watch": "npm run watch",
"start": "./node_modules/.bin/webpack-dev-server",
"test": "npm run lint",
"version": "./node_modules/.bin/json -f package.json -I -e \"this.repository.sha = '$(git log -n1 --pretty=format:%H)'\"",
"watch": "./node_modules/.bin/webpack --progress --colors --watch --watch-poll"
},
"devDependencies": {
"babel-core": "6.9.1",