0
这是CommonJS的格式是否可以交替使用.vue格式与commonJS格式的Vue组件?
Vue.Component('custom-component',{
template : '<p>Some template</p>',
data : {}
methods : {}
});
这是.vue格式
<template>
<p>Some template</p>
</template>
<script>
export default {
data() {
return {};
},
methods : {}
}
</script>
<style>
</style>
我的问题是,你可以写在CommonJS的格式一些组件并写入.vue格式一些组件项目?如果是这样,你如何导入另一种组件?