我还是Vue.js的新手。
我想在这里尝试“ vue-table-2”; (https://jsfiddle.net/matfish2/jfa5t4sm/),但我无法正确运行它。
“依赖项”:{
“ bootstrap3”:“ ^ 3.3.5”,
“ moment”:“ ^ 2.23.0”,
“ vue”:“ ^ 2.5.21”,
“ vue-tables-2”:“ ^ 1.4.70”
}
控制台错误消息;
@HostListener('document:click', ['$event'])
clickout(event) {
if(this.vcRef.element.nativeElement.contains(event.target)) {
alert('Clicked inside');
} else {
alert('Clicked outside');
}
}
我的代码;
[Vue warn]: Failed to mount component: template or render function not defined.
found in
---> <VueClientServer>
<HelloWorld> at src/components/HelloWorld.vue
<App> at src/App.vue
<Root>
答案 0 :(得分:0)
您是否尝试过全局公开jquery,axios,moment,bootstrap和daterangepicker?
https://www.npmjs.com/package/vue-tables-2#date-columns
您可以在main.js中执行此操作:
import axios from 'axios'
window.axios = axios