A ready to run, zero configuration webpack and webpack-dev-server build tool, without project generation
A ready to run, framework agnostic, zero configuration webpack and webpack-dev-server build tool, without project generation.
Babel with ES2016, JSX, TypeScript, Sass, Less and autoprefixer are supported by default.
Included: dev server, unit tests, coverage, and more ! (see features)
npm i -g runpack
You may also use it as a dev dependency.²
Create an index.js or main.js file at the root of your project. You may also use .jsx, .ts or .tsx.
A package.json is not necessary, but if present and the main field is an existing file, it will be used as the entry point.
An index.html file is not mandatory, but if one is found next to the main file, it will be used.
// ES5:require('./path/to/file.css');// ES6 or TypeScript:import './path/to/file.css';
Run the developpment server (default port is already 3000):
runpack server --port 3000
Run the developpment server with a backend server:
runpack server --proxy
Build production files in /dist:
Create a production archive (zip and .tar.gz are supported):
runpack package --type tgz
Run tests with mocha:
Run tests and watch files:
runpack test --watch
Run tests with mocha and generate test reports:
runpack test --test-report
Run tests with mocha and generate a coverage report:
runpack test --coverage
Dump build scripts, generate npm commands and install dev depenencies (may be irreversible !):
runpack server --favicon path/to/favicon
Get help on a specific command:
runpack <command> --help