Unit tests in Vue.js are driven with Jest. Known issues SyntaxError: Unexpected token export This issue is most likely caused by an empty object export on the component (e.g. data() {return {}}).
Category: Vue.js
Vue.js: new project
Install/update vue-cli1 $ npm install -g vue-cli OR $ npm update -g vue-cli Create new project $ vue init <template-name> <project-name> webpack is recommended for sophisticated, scaleable projects. You can also use webpack-simple if you only need the basic development functionality. Install node modules $ cd <project-name> $ npm install Add to […]
Ember.js <> Vue.js
This page documents how different tasks can be done in either Ember.js or Vue.js. Template If/Else Ember.js Vue.js <div>{{if isTrue ‘truthy’ ‘falsy’}}</div> <div>{{ isTrue ? ‘truthy’ : ‘falsy’ }}</div> {{#if isTrue}} <div>truthy</div> {{else}} <div>falsy</div> {{/if}} <div v-if=”isTrue”>truthy</div> <div v-else>falsy</div> Loops Ember.js Vue.js <ul> {{#each items as | item |}} <li>{{ item }}</li> {{/each}} </ul> <ul> […]