How can I use Elixir + Vueify like the Vue-Hackernews sample?
They use some command like this at the package.json
....
"scripts": {
"dev": "watchify -v -t vueify -e src/main.js -o build/build.js",
"build": "./node_modules/watchify/node_modules/.bin/browserify -t vueify src/main.js | uglifyjs -c -m > build/build.js"
}
...
But I do not know how to use it with Laravel Elixir
sudo npm install laravel-elixir-browserify vue vueify --save
In your gulpfile.js
add the following:
var elixir = require('laravel-elixir');
var vueify = require('laravel-elixir-browserify').init("vueify");
elixir(function(mix) {
// resources/assets/js/main.js
mix.vueify('main.js', {insertGlobals: true, transform: "vueify", output: "public/js"});
});
Be Happy =D
Laravel Elixir Browserify Extension Doc Click Here