Deploy to GitHub Pages #12
  
    
      This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
      Learn more about bidirectional Unicode characters
    
  
  
    
  | name: Deploy to GitHub Pages | |
| on: | |
| workflow_dispatch: | |
| permissions: | |
| contents: read | |
| pages: write # required | |
| id-token: write # required | |
| concurrency: | |
| group: "pages" | |
| cancel-in-progress: true | |
| jobs: | |
| build: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v4 | |
| # (Optional) Setup Node if you’re building a JS site. Remove if not needed. | |
| - name: Setup Node | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: '20' | |
| cache: 'npm' | |
| # (Optional) Install & build – customize for your toolchain | |
| - name: Install deps | |
| run: npm ci | |
| - name: Build | |
| run: npm run build:lib && npm run build:docs | |
| # Upload the directory that contains your built site: | |
| # Vite/React/Angular often output to "dist" or "build" | |
| - name: Upload Pages artifact | |
| uses: actions/upload-pages-artifact@v3 | |
| with: | |
| path: ./dist/pioneer-charts-docs/browser # <-- change to your build output folder (e.g., ./build or ./public) | |
| deploy: | |
| environment: | |
| name: github-pages | |
| url: ${{ steps.deployment.outputs.page_url }} | |
| needs: build | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Deploy to GitHub Pages | |
| id: deployment | |
| uses: actions/deploy-pages@v4 |