Skip to content

Add widgetConfig docs and interactive demo with production presets. (… #3

Add widgetConfig docs and interactive demo with production presets. (…

Add widgetConfig docs and interactive demo with production presets. (… #3

Workflow file for this run

name: Deploy demo to GitHub Pages
on:
push:
branches: [ main, master ]
workflow_dispatch:
permissions:
contents: read
pages: write
id-token: write
concurrency:
group: pages
cancel-in-progress: true
jobs:
deploy:
runs-on: ubuntu-latest
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: 20
cache: npm
- name: Install and build
run: |
npm ci
npm run build
- name: Prepare site
run: |
mkdir -p _site
cp -R demo dist _site/
mkdir -p _site/node_modules/@modelcontextprotocol _site/node_modules/zod
cp -R node_modules/@modelcontextprotocol/sdk _site/node_modules/@modelcontextprotocol/
cp -R node_modules/zod _site/node_modules/
cat > _site/index.html <<'EOF'
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta http-equiv="refresh" content="0; url=./demo/" />
<title>Angie SDK Demos</title>
</head>
<body>
<p><a href="./demo/">Angie SDK demos</a></p>
</body>
</html>
EOF
- name: Setup Pages
uses: actions/configure-pages@v5
- name: Upload artifact
uses: actions/upload-pages-artifact@v3
with:
path: _site
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v4