Skip to content

Publish bundle to npmjs.com #4

Publish bundle to npmjs.com

Publish bundle to npmjs.com #4

Workflow file for this run

name: "Publish bundle to npmjs.com"
on:
push:
tags:
- "v[0-9]+.[0-9]+.[0-9]+*"
jobs:
test:
uses: "./.github/workflows/test.yml"
publish-to-npmjs:
name: "Publish to npmjs.com"
needs:
- "test"
runs-on: "ubuntu-latest"
steps:
- name: "Check out repository"
uses: "actions/checkout@v3"
- name: "Setup NodeJS"
uses: "actions/setup-node@v3"
with:
node-version: "18.x"
registry-url: "https://registry.npmjs.org"
- name: "Install dependencies"
run: "npm install"
- name: "Build"
run: "npm run build"
- name: "Publish to npmjs.com"
run: |
npm publish --access public
env:
NODE_AUTH_TOKEN: "${{secrets.NPM_DEPLOY_TOKEN}}"