iw-laravel-elixir-webpack
v0.2.3-a
Published
Laravel Elixir Webpack Extension (derived from Joseph Cohen's laravel-elixir-weback with minor change)
Downloads
4
Maintainers
Readme
laravel-elixir-webpack
Simple extension to laravel elixir to build javascript bundle with webpack.
Install
npm install --save-dev laravel-elixir-webpack
Usage
Example Gulpfile:
var elixir = require("laravel-elixir");
require("laravel-elixir-webpack");
elixir(function(mix) {
mix.webpack("app.js");
});
First argument is the entry point of your application (default directory is resources/assets/js). In third argument you could pass webpack options. In production bundle will be compressed.
Advanced example
elixir(function(mix) {
mix.webpack("app.js", {
outputDir: "public/js",
entry: {
app: "src/app.js",
test: "test/test.js",
},
output: {
filename: "bundle.js"
}
});
});