Skip to content

fix: update import types #9

fix: update import types

fix: update import types #9

Workflow file for this run

name: deploy
permissions:
contents: write
on:
push:
branches:
- master
paths-ignore:
- README.md
jobs:
deploy:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Setup Node
uses: actions/setup-node@v3
with:
node-version: '16'
- name: Cache dependencies
uses: actions/cache@v3
with:
path: ~/.npm
key: ${{ runner.os }}-node-${{ hashFiles('**/package-lock.json') }}
restore-keys: |
${{ runner.os }}-node-
- run: npm install
- run: npm run build
- name: Extract Sandbox
run: |
# extract prebuilt codesandbox, to reduce build time
wget -O- https://github.com/NetEase/codesandbox-client/releases/latest/download/codesandbox.tar.xz | tar xJvf - -C ./dist
# redirect root path to /designer if it's not in iframe
sed -i "s|</head>|<script>(function(){if(window.top===window)window.location.href=\"/designer\"})()</script></head>|" ./dist/index.html
- name: Add CNAME
run: echo "tango-demo.musicfe.com" > ./dist/CNAME
- name: Deploy
uses: peaceiris/actions-gh-pages@v3
with:
publish_dir: ./dist
github_token: ${{ secrets.GITHUB_TOKEN }}