Closed
Description
I'm just getting started with vue-cli
and wanted to try building an empty copy of the webpack
template for deployment. This is what I did:
vue init webpack gazpachoapp
cd gazpachoapp
npm install
vue build --prod src/main.js
That last command gives an error:
ERROR in ./src/router/index.js
Module not found: Error: Can't resolve '@/components/Hello' in '/home/ubuntu/workspace/gazpachoapp/src/router'
@ ./src/router/index.js 3:0-39
@ ./src/main.js
@ multi src/main.js
The if I change that line in src/router/index.js
to:
import Hello from '../components/Hello'
it works, but when I build and start serving the dist
folder it looks totally blank in the browser. Am I doing something wrong?
Thanks!
Metadata
Metadata
Assignees
Labels
No labels