Created
December 5, 2015 23:48
-
-
Save bmadigan/04ffe07df2b0cd002891 to your computer and use it in GitHub Desktop.
Vueify Elixir
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Gulfile | |
var elixir = require('laravel-elixir'); | |
require('laravel-elixir-vueify'); | |
elixir(function(mix) { | |
mix.sass('all.scss'); | |
mix.browserify('main.js'); | |
}); | |
// main.js | |
var Vue = require('vue'); | |
import Greeter from './components/Greeter.vue'; | |
import AsideProfile from './components/AsideProfile.vue'; | |
new Vue({ | |
el: '#app', | |
components: { | |
Greeter, | |
AsideProfile | |
}, | |
ready() { | |
console.log('Vue and Vueify all set to go!'); | |
} | |
}); | |
// Components/AsideProfile.vue | |
<template> | |
<sidebar show="{{@showRight}}" placement="right" header="{{ name }}" width="350"> | |
Here is the body of thing with a new {{ email }} | |
</sidebar> | |
</template> | |
<script> | |
import Vuestrap from 'vue-strap'; | |
export default { | |
components: { | |
'aside':Vuestrap.aside | |
}, | |
data() { | |
return { | |
name: 'Brad Smith', | |
email: '[email protected]' | |
}; | |
} | |
}; | |
</script> | |
<style> | |
h1 { | |
color: #888888; | |
} | |
</style> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment