Skip to content

Publish @fusionauth/react-sdk #1

Publish @fusionauth/react-sdk

Publish @fusionauth/react-sdk #1

name: Publish @fusionauth/react-sdk
on: workflow_dispatch
jobs:
test:
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [18.x, 20.x]
steps:
- uses: actions/checkout@v3
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node-version }}
cache: 'npm'
- name: React SDK - Install packages
run: yarn install --frozen-lockfile
- name: React SDK - Test
run: npm run test:sdk-react
publish-sdk-react:
needs: test
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Use Node.js 20
uses: actions/setup-node@v3
with:
node-version: 20
registry-url: https://registry.npmjs.org/
- run: yarn install --frozen-lockfile
- name: React SDK - Build
run: npm run build:sdk-react
- name: React SDK - Publish
working-directory: ./packages/sdk-react/dist
run: npm publish --dry-run
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}