How to Set up Vue.js project?
Using CLI Command Line
Vue.js also provides CLI to install the vue and get started with the server activation (if you have node.js installed).
To install using CLI, we need to have CLI installed which is done using the following command. The following command will install vue-cli globally.
Think of it like buying a tool, which you purchase once(free in our case) and can use it any number of times. So for setting up another project from next time, this command is not required.
npm install -g vue-cli
Following is the command to create the project using Webpack. This command pulls a webpack template, prompts for some information and generate a project in directory/folder myproject.
vue init webpack myproject
Change directory to your project folder
Install all the dependencies required by the template as listed in package.json file.
This command will start your local http server, open the browser and your default hosted web page will be shown.
npm run dev