docs: Simplify installing Storybook with npx (#5788)

Reduce two-step install to just one step (per the latest storybook docs)

Change (i) `npm install -g @storybook/cli` and (ii) `sb init` to `npx -p @storybook/cli sb init`

Refs: https://storybook.js.org/basics/quick-start-guide/
This commit is contained in:
Sagir Khan
2018-11-14 21:24:02 +05:30
committed by Ian Sutherland
parent 0c9c97a778
commit d72256c7f8

View File

@@ -22,16 +22,10 @@ You can also deploy your Storybook or style guide as a static app. This way, eve
Storybook is a development environment for React UI components. It allows you to browse a component library, view the different states of each component, and interactively develop and test components.
First, install the following npm package globally:
Run the following command inside your apps directory:
```sh
npm install -g @storybook/cli
```
Then, run the following command inside your apps directory:
```sh
sb init
npx -p @storybook/cli sb init
```
After that, follow the instructions on the screen.