|
1 |
| -# create-html5-boilerplate |
2 |
| -npx for html5-boilerplate |
| 1 | +# Create HTML5 Boilerplate |
3 | 2 |
|
4 | 3 | [](https://coveralls.io/github/h5bp/create-html5-boilerplate?branch=master)
|
| 4 | + |
| 5 | +Quick start for HTML5 Boilerplate. Get up and running with one command. |
| 6 | + |
| 7 | +## Getting Started |
| 8 | + |
| 9 | +You can get started using one of three options- `npx`, `npm init`, or |
| 10 | +`yarn create` |
| 11 | + |
| 12 | +Using `npx` |
| 13 | + |
| 14 | +```sh |
| 15 | +npx create-html5-boilperlate new-site |
| 16 | +cd new-site |
| 17 | +npm install |
| 18 | +npm start |
| 19 | +``` |
| 20 | + |
| 21 | +Using `npm init` |
| 22 | + |
| 23 | +```sh |
| 24 | +npm init create-html5-boilperlate new-site |
| 25 | +cd new-site |
| 26 | +npm install |
| 27 | +npm start |
| 28 | +``` |
| 29 | + |
| 30 | +Using yarn |
| 31 | + |
| 32 | +```sh |
| 33 | +yarn create html5-boilperlate new-site |
| 34 | +cd new-site |
| 35 | +npm install |
| 36 | +npm start |
| 37 | +``` |
| 38 | + |
| 39 | +These commands are equivalent and do the following: |
| 40 | + |
| 41 | +1. Dowloads and installs the latest version of HTML5-Boilerplate |
| 42 | +2. Bundles site assets and tart a web server using [`parcel`](https://parceljs.org/) |
| 43 | +3. Opens a web browser pointed to http://localhost:1234/ |
| 44 | + |
| 45 | +## Requirements |
| 46 | + |
| 47 | +`create-html5-boilerplate` is cross-platform. It works whereever node and npm work. |
| 48 | +The only requirements are for `npx`, which requires npm version 5.2 or greater and |
| 49 | +`npm init` which requires an npm version greater than 6.0. If you're stuck on an |
| 50 | +older version of npm you can still use `create-html5-boilerplate` by running the |
| 51 | +following command to install the project globally. |
| 52 | + |
| 53 | +```sh |
| 54 | +npm install -g create-html5-boilperlate |
| 55 | +``` |
| 56 | + |
| 57 | +Then you can use create-html5-boilerplate as in the following example |
| 58 | + |
| 59 | +```sh |
| 60 | +create-html5-boilperlate new-site |
| 61 | +cd new-site |
| 62 | +npm install |
| 63 | +npm start |
| 64 | +``` |
| 65 | + |
| 66 | +## Installing Specific Versions |
| 67 | + |
| 68 | +You can also install a specific version: |
| 69 | + |
| 70 | +```sh |
| 71 | +npx create-html5-boilerplate new-site --release=7.2.0 |
| 72 | +cd new-site |
| 73 | +npm install |
| 74 | +npm start |
| 75 | +``` |
0 commit comments