vueify+node: compile separate .vue files

98 views Asked by At

Is it possible to setup vueify this way, so it compiles single .vue files to corresponding .js files?

For example:

Input: my-component.vue

<template>
    <div>{{ message }}</div>
</template>
<script>
    module.exports = {
        data() {
            return {
                message: 'Hello World',
            };
        },
    };
</script>

Output: my-component.js

Vue.component('my-component', {
   template: '<div>{{ message }}</div>',
   data() {
       return {
           message: 'Hello World',
       };
   },
});
0

There are 0 answers