Skip to content

Use OIDC to publish the React package to npmjs#192

Open
mrudatsprint wants to merge 13 commits into
mainfrom
miker/npm-publish-oidc
Open

Use OIDC to publish the React package to npmjs#192
mrudatsprint wants to merge 13 commits into
mainfrom
miker/npm-publish-oidc

Conversation

@mrudatsprint
Copy link
Copy Markdown
Collaborator

@mrudatsprint mrudatsprint commented May 14, 2026

Use OIDC to publish the React package to npmjs vs a GitHub token in Secrets. NPM doesn't want us using tokens anymore.

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR updates the React SDK publishing workflow to use npm OIDC trusted publishing/provenance instead of a stored npm token.

Changes:

  • Adds GitHub Actions permissions for OIDC publishing.
  • Updates the React SDK publish step to use npm publish --provenance --access public.
  • Removes the redundant private: false field from the React package manifest.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 2 comments.

File Description
.github/workflows/publish-sdk-react.yml Updates publish workflow permissions and npm publish command for OIDC provenance.
packages/sdk-react/package.json Removes explicit private: false from the package metadata.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread .github/workflows/publish-sdk-react.yml Outdated
Comment thread .github/workflows/publish-sdk-react.yml
Comment thread packages/sdk-react/package.json
@mrudatsprint mrudatsprint marked this pull request as ready for review May 15, 2026 18:21
@mrudatsprint mrudatsprint requested review from a team as code owners May 15, 2026 18:21
Comment thread .github/workflows/publish-sdk-react.yml Outdated
node-version: 20
registry-url: https://registry.npmjs.org/
- run: yarn install --frozen-lockfile
node-version: '20'
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is there any reason not to upgrade to a newer node version since node 20 is EOL?

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm going to use 24 as the latest version and test with 22 & 24. 26 is going to require core code updates as well as test updates and I'll create a separate issue to support 26.

Comment thread .github/workflows/publish-sdk-react.yml Outdated
@@ -27,16 +31,22 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Update this to checkout@v6

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Updated to checkout@v6

Comment thread .github/workflows/publish-sdk-react.yml Outdated
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should maybe update this matrix to drop at least 18 and add 22, 24, and 26

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm going to use 24 as the latest version and test with 22 & 24. 26 is going to require core code updates as well as test updates and I'll create a separate issue to support 26.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants