# Deprecated

[Rollup][rollup] and [Buble][buble] were awesome, no reason to maintain a project which has similar purpose but no more feature.

[rollup]: https://github.com/rollup/rollup
[buble]: https://www.npmjs.com/package/buble

# webel

Simple javascript bundler integrated webpack and babel.

## Introduction

Webel is useful for a small project or testing some features. Webel also has watch mode to build application immediately for developing.

## Installation

```javascript
$ npm install --save-dev webel
```

## Usage

The compiled result is written into memory-fs and has been piped to _stdout_ in default, you can pipe the result into a file simply.

In `normal mode`, result will be piped to \`_stdout_\` but won't in `watch mode`, you can use option `--output` to export the result into a file. If you use `--watch` without `--output`, the result will just stored in memory, its works like a dynamic syntax corrector.

#### CLI

```javascript
// Build an application
$ webel entry.js > bundle.js

// Watch an application
$ webel --watch entry.js -o bundle.js
```

#### NPM Script

```javascript
// package.json
...
"scripts": {
  "build": "webel index.js -o dist/app.js",
  "watch": "webel index.js -wo dist/app.js"
},
...
```

## Options

| Usage           | Description                       | Alias |
| --------------- | --------------------------------- | ----- |
| `--watch`       | Start in watch mode               | `-w`  |
| `--output file` | Pipe result to the specified file | `-o`  |
| `--minimize`    | Minimize the result               | `-m`  |
| `--source-map`  | Generate source map file, works only if `-o` has provided | `-s` |

## Configuration

You can also provide a configuration file to webel for more customizable, just create an file named `webel.config.js` under your project directory.

Remember, configuration file __only__ works if it is `--dev` installation.

`babel.plugins` and `babel.presets` will __extends__ the default values.

`externals` allows _Array<String>_ and also _Boolean_ value. (default: true) (externals === true ? nodeExternals() : [])

#### Quick look

```javascript
// webel.config.js defaults
module.exports = {
  babel: {
    plugins: [
      'transform-async-to-generator',
      'transform-runtime'
    ],
    presets: [
      ['es2015', { modules: false }],
      'stage-2'
    ]
  },
  externals: [
    require('webpack-node-externals')()
  ],
  plugins: []
}
```

#### In used plugins

- `webpack.NoErrorsPlugin` : When there are errors while compiling, skips the emitting phase.
- `progress-bar-webpack-plugin` : For more friendly compiling messages.

[Configuration examples](./examples/)
