fix #149
This file contains 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: Chromatic | |
on: push | |
jobs: | |
publish: | |
runs-on: ubuntu-latest | |
steps: | |
# https://github.com/actions/checkout | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
# https://nodejs.org/api/corepack.html | |
- name: Enable corepack (for pnpm) | |
run: corepack enable | |
# https://github.com/actions/setup-node | |
- name: Setup Node.js | |
uses: actions/setup-node@v4 | |
with: | |
cache: pnpm | |
node-version: 20 | |
# https://pnpm.io/cli/install | |
- name: Install Node.js dependencies with pnpm | |
run: > | |
pnpm install | |
--frozen-lockfile | |
- name: Build package | |
run: > | |
pnpm run build | |
- name: Publish to Chromatic | |
uses: chromaui/action@v1 | |
with: | |
token: ${{ secrets.GITHUB_TOKEN }} | |
projectToken: ${{ secrets.CHROMATIC_PROJECT_TOKEN }} |