Skip to content

Commit

Permalink
[docs] Add post-update to examples so they run on CodeSandbox (#19605)
Browse files Browse the repository at this point in the history
  • Loading branch information
garethx authored Feb 7, 2020
1 parent c1de18f commit 7f4b81f
Show file tree
Hide file tree
Showing 7 changed files with 15 additions and 6 deletions.
3 changes: 2 additions & 1 deletion examples/gatsby-theme/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
"scripts": {
"develop": "gatsby develop",
"build": "gatsby build",
"serve": "gatsby serve"
"serve": "gatsby serve",
"post-update": "echo \"codesandbox preview only, need an update\" && yarn upgrade --latest"
}
}
3 changes: 2 additions & 1 deletion examples/gatsby/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
"scripts": {
"develop": "gatsby develop",
"build": "gatsby build",
"serve": "gatsby serve"
"serve": "gatsby serve",
"post-update": "echo \"codesandbox preview only, need an update\" && yarn upgrade --latest"
}
}
3 changes: 2 additions & 1 deletion examples/nextjs-with-typescript/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,8 @@
"scripts": {
"dev": "next",
"build": "next build",
"start": "next start"
"start": "next start",
"post-update": "echo \"codesandbox preview only, need an update\" && yarn upgrade --latest"
},
"devDependencies": {
"@types/next": "latest",
Expand Down
3 changes: 2 additions & 1 deletion examples/nextjs/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
"scripts": {
"dev": "next",
"build": "next build",
"start": "next start"
"start": "next start",
"post-update": "echo \"codesandbox preview only, need an update\" && yarn upgrade --latest"
}
}
3 changes: 3 additions & 0 deletions examples/preact/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,9 @@ Install it and run:
npm install
npm run start
```
or:

[![Edit on CodeSandbox](https://codesandbox.io/static/img/play-codesandbox.svg)](https://codesandbox.io/s/github/mui-org/material-ui/tree/master/examples/preact)

## The idea behind the example

Expand Down
3 changes: 2 additions & 1 deletion examples/preact/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,8 @@
"scripts": {
"start": "node scripts/start.js",
"build": "node scripts/build.js",
"test": "node scripts/test.js"
"test": "node scripts/test.js",
"post-update": "echo \"codesandbox preview only, need an update\" && yarn upgrade --latest"
},
"browserslist": [
">0.2%",
Expand Down
3 changes: 2 additions & 1 deletion examples/ssr/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@
"start": "npm-run-all -p build serve",
"build": "webpack -w",
"serve": "nodemon --ignore ./build --exec babel-node -- server.js",
"production": "cross-env NODE_ENV=production npm start"
"production": "cross-env NODE_ENV=production npm start",
"post-update": "echo \"codesandbox preview only, need an update\" && yarn upgrade --latest"
}
}

0 comments on commit 7f4b81f

Please sign in to comment.