Skip to content

Converted to static SPA #4

Converted to static SPA

Converted to static SPA #4

Workflow file for this run

name: Deploy to GitHub Pages
on:
push:
branches:
- main
permissions:
contents: read
pages: write
id-token: write
concurrency:
group: pages
cancel-in-progress: true
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Node
uses: actions/setup-node@v4
with:
node-version: 22
cache: npm
- name: Install dependencies
run: npm install
- name: Build
run: npm run build
env:
# If deploying to https://<user>.github.io/<repo>/ uncomment and set the repo name.
# VITE_BASE: /<repo>/
VITE_BASE: /
- name: SPA fallback (404.html)
run: cp dist/index.html dist/404.html
- name: Add .nojekyll
run: touch dist/.nojekyll
- name: Upload GitHub Pages artifact
uses: actions/upload-pages-artifact@v3
with:
path: dist
deploy:
runs-on: ubuntu-latest
needs: build
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
steps:
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v4