4👍
If you use Webpack, you can add the below code snippet into your webpack.config.js
resolve: {
alias: {
components: path.resolve(__dirname, 'src/components/')
}
}
- [Vuejs]-Vue: beforeEach is not a function
- [Vuejs]-Error in data(): "TypeError: Cannot read property 'length' of undefined" (Vue.js)
0👍
- Add
jsconfig.json
file in your root directory - Place the code below to the file:
{
"compilerOptions": {
"baseUrl": "src"
},
"include": ["src"]
}
- Restart your npm script
Source:stackexchange.com