Skip to content

Commit bf85566

Browse files
committed
Update shopping-cart example
1 parent 773cc39 commit bf85566

File tree

2 files changed

+12
-15
lines changed

2 files changed

+12
-15
lines changed

examples/shopping-cart/README.md

Lines changed: 11 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -4,14 +4,18 @@ See [NuclearJS: Getting Started](https://optimizely.github.io/nuclear-js/docs/01
44

55
Taken (and slightly modified) from [https://github.com/voronianski/flux-comparison](https://github.com/voronianski/flux-comparison)
66

7-
## To Run
7+
## Running
88

9-
The compiled files are checked in simply, open the `index.html` file
9+
You must have [npm](https://www.npmjs.org/) installed on your computer.
10+
From the root project directory run these commands from the command line:
1011

11-
## To modify
12+
`npm install`
1213

13-
**Start the webpack watch task:**
14+
This will install all dependencies.
1415

15-
```sh
16-
webpack -w
17-
```
16+
To build the project, first run this command:
17+
18+
`npm start`
19+
20+
After starting the watcher, you can open `index.html` in your browser to
21+
open the app.

examples/shopping-cart/package.json

Lines changed: 1 addition & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,7 @@
11
{
22
"main": "js/app.js",
33
"scripts": {
4-
"start": "../node_modules/watchify/bin/cmd.js js/app.js -o build/bundle.js -v -d",
5-
"build": "browserify js/app.js > build/bundle.js"
6-
},
7-
"browserify": {
8-
"transform": [
9-
"babelify",
10-
"envify"
11-
]
4+
"start": "./node_modules/webpack/bin/webpack.js --watch --progress"
125
},
136
"dependencies": {
147
"nuclear-js": "^1.0.5",

0 commit comments

Comments
 (0)