Closed chbinghu closed 7 years ago
This can be resolved by adding this to your webpack config:
resolve: {
alias: {
vue: 'vue/dist/vue.js'
}
}
See below: https://github.com/vuejs-templates/webpack/issues/215
Hey @charliekassel and who doesn't use webpack? I use Rollup and runtime Vue.
Hi @charliekassel, I am also experiencing this error.
I already have resolve: { alias: { vue: 'vue/dist/vue.js' } }
in my webpack config.
Interestingly, I am also using vue2-timepicker component without any problems. Not sure why yours is not working.
Can also be solved by using:
import Vue from 'vue/dist/vue.js';
In stead of:
import Vue from 'vue';
resolve: {
alias: {
'vue$': 'vue/dist/vue.js'
}
}
This works for me. Using vue: 'vue/dist/vue.js'
will cause the error This dependency was not found
.
You can easily fix this, for example you have a main javascript file called, main.js
and there instead of var Vue = require('vue');
you should do stuff like var Vue = require('./node_modules/vue/dist/vue.js');
basically it connects the Vue
thanks for your datepicker, and I got a problem in vue2 vue.common.js:2611[Vue warn]: You are using the runtime-only build of Vue where the template option is not available. Either pre-compile the templates into render functions, or use the compiler-included build. (found in component).
I just use it in a *.vue