create-svelte-site
Create a Svelte or Sapper site in a single command.
Last updated 4 months ago by gojutin .
MIT · Repository · Bugs · Original npm · Tarball · package.json
$ cnpm install create-svelte-site 
SYNC missed versions from official npm registry.

Create Svelte Site oclif Version Downloads/week License

Create a Svelte or Sapper site in a single command.

create-svelte-site gif

Usage

Creating a Site

You’ll need to have Node 8.10.0 or later on your local development machine (but it’s not required on the server). You can use nvm (macOS/Linux) or nvm-windows to easily switch Node versions between different projects.

With npx

  npx create-svelte-site my-site

With npm

  npm init svelte-site my-site

With yarn

  yarn create svelte-site my-site

Note: We are using my-site as an example. This can be any project name you choose.

You will be prompted to select a template from the official Svelte template library.

create-svelte-site prompt

After you make your selection, your new site will be created in a directory named my-site inside the current folder.

Next steps:

Navigate to the newly created directory.

cd my-site

Install the dependencies

npm install

or

yarn

Then, start up the development server.

npm run dev

Your site will be available at http://localhost:5000.

Note: npm run dev does not apply to the Svelte (component) project type.

Commands

Here is a full list of the options and the corresponding templates that are executed.

Under the hood, this library is using nodegit to generate your new project using official Svelte and community templates.

Command Template
Svelte (rollup) svelte/template
Svelte (webpack) svelte/template-webpack
Svelte (component) svelte/component-template
Svelte (custom element) gojutin/svelte-custom-element
Sapper (rollup) sveltejs/sapper-template#rollup
Sapper (webpack) sveltejs/sapper-template#webpack

Useful Resources

Current Tags

  • 0.0.8                                ...           latest (4 months ago)

8 Versions

  • 0.0.8                                ...           4 months ago
  • 0.0.7                                ...           7 months ago
  • 0.0.6                                ...           7 months ago
  • 0.0.5                                ...           7 months ago
  • 0.0.4                                ...           7 months ago
  • 0.0.3                                ...           7 months ago
  • 0.0.2                                ...           7 months ago
  • 0.0.1                                ...           7 months ago
Maintainers (1)
Downloads
Today 0
This Week 0
This Month 0
Last Day 0
Last Week 0
Last Month 0
Dependencies (8)
Dependents (0)
None

Copyright 2014 - 2016 © taobao.org |