Skip to content

Separated the embedded example #28

Separated the embedded example

Separated the embedded example #28

Workflow file for this run

name: Build and Deploy
on:
push:
branches:
- main
jobs:
build-and-deploy:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v3
- name: Set up Node.js
uses: actions/setup-node@v3
with:
node-version: '16'
- name: Install dependencies
run: npm install
- name: Build project
run: npm run build
- name: Check if dist directory exists
run: |
if [ ! -d "./dist" ]; then
echo "Error: ./dist directory does not exist."
exit 1
fi
- name: Copy index.html and tester.js to dist
run: |
cp index.html dist/
- name: Deploy to GitHub Pages
uses: peaceiris/actions-gh-pages@v3
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_branch: gh-pages
publish_dir: ./dist