Skip to content

sillydeveloper/vue-cli

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 

Repository files navigation

vue-cli

A simple CLI for scaffolding Vue.js projects.

Installation

$ npm install -g vue-cli

Usage

$ vue init webpack my-project
$ cd my-project
$ npm install
$ npm run dev

The above command pulls the template from vuejs-templates/webpack, prompts for some information, and generates the project at .my-project/.

When a new template is added to the vuejs-templates organization, you will be able to run vue init <template-name> <project-name> to use that template.

You can run vue list to see all available official templates.

Custom Templates

It's unlikely to make everyone happy with the official templates. You can simply fork an official template and then use it via vue-cli with:

vue init username/repo my-project

Where username/repo is the GitHub repo shorthand for your fork.

You can also create your own template from scratch:

  • A template repo must have a template directory that holds the template files.

  • All template files will be piped through Handlebars for simple templating - vue-cli will automatically infer the prompts based on {{}} interpolations found in the files.

  • A template repo may have a meta.json file that provides a schema for the prompts. The schema will be passed to prompt-for as options. See example.

About

Simple CLI for scaffolding Vue.js projects

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • JavaScript 98.8%
  • Other 1.2%