Sunday 9 December 2018

Init VUE-CLI && deployment

Init VUE-CLI

// Install node, and NPM (MAKE sure check $PATH variable)
# .....
// Install vue-cli via NPM
# sudo npm install -g vue-cli

// Init a VUE project using vue-cli webpack(library && dependency manager for JS)

# vue init webpack-simple vue-cli-project

// To start develoment server localhost:8080
# cd vue-cli-project
# npm install
# npm run dev (localhost:8080 will be started)

// We can also cd to any existing vue cli proect 
# cd vue-cli-project2
# npm install
# npm run dev (localhost:8080 will be started)

Deploy VUE-CLI

// Build
# npm run build
// upload
index.html && dist/build.js to server

No comments:

Post a Comment