Skip to content

Commit

Permalink
Docs: Stackblitz Support (pinterest#3279)
Browse files Browse the repository at this point in the history
  • Loading branch information
rlingineni authored Nov 15, 2023
1 parent de53e0d commit cd472db
Show file tree
Hide file tree
Showing 3 changed files with 19 additions and 1 deletion.
4 changes: 3 additions & 1 deletion .vscode/tasks.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,9 @@
"tasks": [
{
"type": "shell",
"command": "yarn start",
"osx": {
"command": "yarn start"
},
"problemMatcher": [],
"label": "Run yarn start on startup",
"presentation": {
Expand Down
3 changes: 3 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -193,5 +193,8 @@
"type": "git",
"url": "https://github.com/pinterest/gestalt"
},
"stackblitz": {
"startCommand": "./scripts/stackblitz.sh"
},
"sideEffects": false
}
13 changes: 13 additions & 0 deletions scripts/stackblitz.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
#!/usr/bin/env sh

# Simplified start script for the stack blitz environment, which can't handle multiple watchers
set -x
set -e

(cd packages/gestalt-design-tokens && yarn build)
(cd packages/gestalt && yarn build)
(cd packages/gestalt-charts && yarn build)
(cd packages/gestalt-datepicker && yarn build)
(cd docs && yarn build-metadata)
(cd docs && (npx next dev))

0 comments on commit cd472db

Please sign in to comment.