0.2.3-a • Published 8 years ago

iw-laravel-elixir-webpack v0.2.3-a

Weekly downloads
1
License
MIT
Repository
github
Last release
8 years ago

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"
        }
    });
});