simple-gulp-webpack-closure_compiler
v1.0.0-rc.4
Published
MyApp =====
Downloads
4
Readme
MyApp
Simplest app with gulp + webpack + closure compiler, support build with current git branch/tag as version for output name
Get Started
Install all dependencies:
$ npm install
Build:
Build dev (without closure compiler + with log)_: gulp --env=dev
Build prod (with closure compiler + without log): gulp
Build test (with closure compiler + with log)___: gulp --env=test
Build test (with closure compiler + without log): gulp --env=test --disable-debug
The output file's version will be detected from current branch/tag name.
For example:
current branch is
develop
=> output file ismy-app-develop.js
current tag is
v1.0.5
=> output file ismy-app-1.0.5.js
For building without closure compiler: open webpack.config.js, comment this code block
plugins: [
new ClosureCompilerPlugin(getClosureCompilerConfig())
]
The output file my-app-x.y.z
will be found in ./dist/ (the dir we serve web from for testing).
Setting up test environment:
[ update later ]
Run dev server:
$ npm run serve
After running dev server successfully, open browser and browse to: http://localhost:8081/play.html# (dev/ when build --env=dev, replace by test or prod for other builds), then check the displayed contents and console log to sure our app works properly.