Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add ESM compatibility #1

Merged
merged 12 commits into from
May 15, 2024
26 changes: 26 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
name: Build SDK

on:
push:
branches: [main]
pull_request:
branches: [main]

jobs:
build:
runs-on: ubuntu-latest

steps:
- name: Checkout code
uses: actions/checkout@v4

- name: Use Node.js
uses: actions/setup-node@v4
with:
node-version: "18"

- name: Install dependencies
run: npm install

- name: Build package
run: npm run build # Replace with your build script
12 changes: 6 additions & 6 deletions .github/workflows/npm-publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,27 +3,27 @@ name: Publish package to npm
on:
push:
branches:
- main # Set this to the branch you want to trigger the publish action
- main # Set this to the branch you want to trigger the publish action

jobs:
build:
runs-on: ubuntu-latest

steps:
- name: Checkout code
uses: actions/checkout@v2
uses: actions/checkout@v4

- name: Use Node.js
uses: actions/setup-node@v2
uses: actions/setup-node@v4
with:
node-version: '14' # Specify the Node.js version
registry-url: 'https://registry.npmjs.org/'
node-version: "18" # Specify the Node.js version
registry-url: "https://registry.npmjs.org/"

- name: Install dependencies
run: npm install

- name: Build package
run: npm run build # Replace with your build script
run: npm run build # Replace with your build script

- name: Publish to npm
run: npm publish --access public
Expand Down
Loading