Skip to content
Closed
Show file tree
Hide file tree
Changes from 41 commits
Commits
Show all changes
42 commits
Select commit Hold shift + click to select a range
184fc43
migrated to pnpm
dougg0k Jul 25, 2025
6b67400
temp type fix and fixed scripts
dougg0k Jul 25, 2025
ebeb2c5
disabled lint in line
dougg0k Jul 25, 2025
4656a57
example possible error fix
dougg0k Jul 25, 2025
8e85d15
Merge branch 'main' of github.com:dougg0k/react-native-node-api into …
dougg0k Jul 25, 2025
40e9221
added skiplibcheck
dougg0k Jul 25, 2025
1a04847
added skiplibcheck in another proj
dougg0k Jul 25, 2025
5c61df5
removed skip lib from a project and added @types
dougg0k Jul 25, 2025
698c6f2
changed ferric dep to actual version back
dougg0k Jul 25, 2025
ee06e8a
add changes
dougg0k Jul 25, 2025
7768127
added released changes
dougg0k Jul 25, 2025
04df8c5
added check
dougg0k Jul 25, 2025
c094863
fixed check
dougg0k Jul 25, 2025
a2f03dc
added check to apple fn
dougg0k Jul 25, 2025
af071fb
try without skiplib
dougg0k Jul 25, 2025
ab6a417
Merge branch 'main' of github.com:dougg0k/react-native-node-api into …
dougg0k Jul 26, 2025
b9c8fb2
added no-sort to recursive pnpm
dougg0k Jul 26, 2025
0e4abe5
updated pnpm lock
dougg0k Jul 26, 2025
3388f85
fix prettier checks
dougg0k Jul 26, 2025
51df6e3
added file to prettier ignore
dougg0k Jul 26, 2025
5cb73f5
Merge remote-tracking branch 'upstream/main' into replace-package-man…
dougg0k Aug 2, 2025
a4e7b67
fixed lock and workspace dependency
dougg0k Aug 2, 2025
44be588
fixed formatting
dougg0k Aug 2, 2025
0f32d7b
Merge remote-tracking branch 'upstream/main' into replace-package-man…
dougg0k Aug 9, 2025
7def782
updated pnpm lock
dougg0k Aug 9, 2025
b26bc86
Merge remote-tracking branch 'upstream/main' into replace-package-man…
dougg0k Sep 1, 2025
10af188
updated pnpm lock
dougg0k Sep 1, 2025
64b7229
fixed typos
dougg0k Sep 1, 2025
2dabae2
removed exists checks
dougg0k Sep 1, 2025
c3fa120
fixed workspace package version
dougg0k Sep 1, 2025
a8c88d2
removed no-sort
dougg0k Sep 1, 2025
338582b
removed and updated more versions
dougg0k Sep 1, 2025
0155394
some versions fixes
dougg0k Sep 1, 2025
a17b508
updated check ci
dougg0k Sep 1, 2025
d169fc4
attempt to fix build
dougg0k Sep 1, 2025
330f017
added bootstrap command to package
dougg0k Sep 1, 2025
7347f21
add no sort to command
dougg0k Sep 1, 2025
e655d71
Merge remote-tracking branch 'upstream/main' into replace-package-man…
dougg0k Sep 22, 2025
94f6660
fixed bad merge
dougg0k Sep 22, 2025
9418c27
fixed another json
dougg0k Sep 22, 2025
2d82138
regenerated pnpm and fixed workspace versions
dougg0k Sep 22, 2025
97ed4eb
changed some versions to workspace
dougg0k Sep 22, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 9 additions & 0 deletions .changeset/cute-cities-march.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
---
"@react-native-node-api/ferric-example": patch
"cmake-rn": patch
"ferric-cli": patch
"@react-native-node-api/test-app": patch
"react-native-node-api": patch
---

Migrated package manager to pnpm
57 changes: 38 additions & 19 deletions .github/workflows/check.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,11 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: pnpm/action-setup@v4
name: Install pnpm
with:
version: "latest"
run_install: false
- uses: actions/setup-node@v4
with:
node-version: lts/jod
Expand All @@ -38,16 +43,15 @@ jobs:
with:
packages: tools platform-tools ndk;${{ env.NDK_VERSION }}
- run: rustup target add x86_64-linux-android
- run: npm ci
- run: npm run build
- run: pnpm install --frozen-lockfile
- run: pnpm build
# Bootstrap host package to get weak-node-api and ferric-example to get types
# TODO: Solve this by adding an option to ferric to build only types or by committing the types into the repo as a fixture for an "init" command
- run: npm run bootstrap --workspace react-native-node-api
- run: npm run bootstrap --workspace @react-native-node-api/ferric-example
- run: npm run lint
- run: pnpm --no-sort --filter react-native-node-api --filter @react-native-node-api/ferric-example bootstrap
- run: pnpm lint
env:
DEBUG: eslint:eslint
- run: npm run prettier:check
- run: pnpm prettier:check
unit-tests:
strategy:
fail-fast: false
Expand All @@ -60,6 +64,11 @@ jobs:
name: Unit tests (${{ matrix.runner }})
steps:
- uses: actions/checkout@v4
- uses: pnpm/action-setup@v4
name: Install pnpm
with:
version: "latest"
run_install: false
- uses: actions/setup-node@v4
with:
node-version: lts/jod
Expand All @@ -73,15 +82,20 @@ jobs:
with:
packages: tools platform-tools ndk;${{ env.NDK_VERSION }}
- run: rustup target add x86_64-linux-android aarch64-linux-android armv7-linux-androideabi i686-linux-android aarch64-apple-ios-sim
- run: npm ci
- run: npm run bootstrap
- run: npm test
- run: pnpm install --frozen-lockfile
- run: pnpm bootstrap
- run: pnpm test
test-ios:
if: github.ref == 'refs/heads/main' || contains(github.event.pull_request.labels.*.name, 'Apple 🍎')
name: Test app (iOS)
runs-on: macos-latest
steps:
- uses: actions/checkout@v4
- uses: pnpm/action-setup@v4
name: Install pnpm
with:
version: "latest"
run_install: false
- uses: actions/setup-node@v4
with:
node-version: lts/jod
Expand All @@ -95,24 +109,29 @@ jobs:
with:
packages: tools platform-tools ndk;${{ env.NDK_VERSION }}
- run: rustup target add x86_64-linux-android aarch64-linux-android armv7-linux-androideabi i686-linux-android aarch64-apple-ios-sim
- run: npm ci
- run: npm run bootstrap
- run: pnpm install --frozen-lockfile
- run: pnpm bootstrap
env:
CMAKE_RN_TRIPLETS: arm64-apple-ios-sim
FERRIC_TARGETS: aarch64-apple-ios-sim
- run: npm run pod-install
- run: pnpm pod-install
working-directory: apps/test-app
- name: Run tests (iOS)
run: npm run test:ios:allTests
run: pnpm test:ios:allTests
# TODO: Enable release mode when it works
# run: npm run test:ios -- --mode Release
# run: pnpm test:ios -- --mode Release
working-directory: apps/test-app
test-android:
if: github.ref == 'refs/heads/main' || contains(github.event.pull_request.labels.*.name, 'Android 🤖')
name: Test app (Android)
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: pnpm/action-setup@v4
name: Install pnpm
with:
version: "latest"
run_install: false
- uses: actions/setup-node@v4
with:
node-version: lts/jod
Expand All @@ -126,8 +145,8 @@ jobs:
with:
packages: tools platform-tools ndk;${{ env.NDK_VERSION }}
- run: rustup target add x86_64-linux-android aarch64-linux-android armv7-linux-androideabi i686-linux-android aarch64-apple-ios-sim
- run: npm ci
- run: npm run bootstrap
- run: pnpm install --frozen-lockfile
- run: pnpm bootstrap
env:
CMAKE_RN_TRIPLETS: x86_64-linux-android
FERRIC_TARGETS: x86_64-linux-android
Expand All @@ -152,10 +171,10 @@ jobs:
sudo udevadm control --reload-rules
sudo udevadm trigger --name-match=kvm
- name: Build weak-node-api for all architectures
run: npm run build-weak-node-api -- --android
run: pnpm build-weak-node-api -- --android
working-directory: packages/host
- name: Build ferric-example for all architectures
run: npm run build -- --android
run: pnpm build -- --android
working-directory: packages/ferric-example
- name: Run tests (Android)
timeout-minutes: 75
Expand All @@ -177,7 +196,7 @@ jobs:
adb logcat > emulator-logcat.txt 2>&1 &
LOGCAT_PID=$!
# Build, install and run the app
npm run test:android:allTests -- --mode Release
pnpm test:android:allTests -- --mode Release
# Wait a bit for the sub-process to terminate, before terminating the emulator
sleep 5
# Stop logcat
Expand Down
9 changes: 7 additions & 2 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,11 @@ jobs:
runs-on: macos-latest
steps:
- uses: actions/checkout@v4
- uses: pnpm/action-setup@v4
name: Install pnpm
with:
version: "latest"
run_install: false
- uses: actions/setup-node@v4
with:
node-version: lts/jod
Expand All @@ -30,13 +35,13 @@ jobs:
with:
packages: tools platform-tools ndk;${{ env.NDK_VERSION }}
- run: rustup target add x86_64-linux-android aarch64-linux-android armv7-linux-androideabi i686-linux-android aarch64-apple-ios-sim
- run: npm ci
- run: pnpm install --frozen-lockfile

- name: Create Release Pull Request or Publish to npm
id: changesets
uses: changesets/action@v1
with:
publish: npm run release
publish: pnpm release
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
2 changes: 2 additions & 0 deletions .prettierignore
Original file line number Diff line number Diff line change
Expand Up @@ -11,3 +11,5 @@ packages/node-addon-examples/examples
packages/node-tests/node
packages/node-tests/tests
packages/node-tests/*.generated.js

pnpm-lock.yaml
88 changes: 44 additions & 44 deletions apps/test-app/package.json
Original file line number Diff line number Diff line change
@@ -1,46 +1,46 @@
{
"name": "@react-native-node-api/test-app",
"private": true,
"version": "0.2.0",
"scripts": {
"metro": "react-native start --no-interactive",
"android": "react-native run-android --no-packager --active-arch-only",
"ios": "react-native run-ios --no-packager",
"pod-install": "cd ios && pod install",
"test:android": "mocha-remote --exit-on-error -- concurrently --kill-others-on-fail --passthrough-arguments npm:metro 'npm:android -- {@}' --",
"test:android:allTests": "MOCHA_REMOTE_CONTEXT=allTests node --run test:android -- ",
"test:android:nodeAddonExamples": "MOCHA_REMOTE_CONTEXT=nodeAddonExamples node --run test:android -- ",
"test:android:nodeTests": "MOCHA_REMOTE_CONTEXT=nodeTests node --run test:android -- ",
"test:android:ferricExample": "MOCHA_REMOTE_CONTEXT=ferricExample node --run test:android -- ",
"test:ios": "mocha-remote --exit-on-error -- concurrently --passthrough-arguments --kill-others-on-fail npm:metro 'npm:ios -- {@}' --",
"test:ios:allTests": "MOCHA_REMOTE_CONTEXT=allTests node --run test:ios -- ",
"test:ios:nodeAddonExamples": "MOCHA_REMOTE_CONTEXT=nodeAddonExamples node --run test:ios -- ",
"test:ios:nodeTests": "MOCHA_REMOTE_CONTEXT=nodeTests node --run test:ios -- ",
"test:ios:ferricExample": "MOCHA_REMOTE_CONTEXT=ferricExample node --run test:ios -- "
},
"dependencies": {
"@babel/core": "^7.26.10",
"@babel/preset-env": "^7.26.9",
"@babel/runtime": "^7.27.0",
"@react-native-community/cli": "^20.0.2",
"@react-native-community/cli-platform-android": "^20.0.2",
"@react-native-community/cli-platform-ios": "^20.0.2",
"@react-native-node-api/ferric-example": "*",
"@react-native-node-api/node-addon-examples": "*",
"@react-native-node-api/node-tests": "*",
"@react-native/babel-preset": "0.81.4",
"@react-native/metro-config": "0.81.4",
"@react-native/typescript-config": "0.81.4",
"@rnx-kit/metro-config": "^2.1.1",
"@types/mocha": "^10.0.10",
"@types/react": "^19.1.0",
"concurrently": "^9.1.2",
"mocha": "^11.6.0",
"mocha-remote-cli": "^1.13.2",
"mocha-remote-react-native": "^1.13.2",
"react": "19.1.0",
"react-native": "0.81.4",
"react-native-node-api": "*",
"react-native-test-app": "^4.4.7"
}
"name": "@react-native-node-api/test-app",
"private": true,
"version": "0.2.0",
"scripts": {
"metro": "react-native start --no-interactive",
"android": "react-native run-android --no-packager --active-arch-only",
"ios": "react-native run-ios --no-packager",
"pod-install": "cd ios && pod install",
"test:android": "mocha-remote --exit-on-error -- concurrently --kill-others-on-fail --passthrough-arguments npm:metro 'npm:android -- {@}' --",
"test:android:allTests": "MOCHA_REMOTE_CONTEXT=allTests node --run test:android -- ",
"test:android:nodeAddonExamples": "MOCHA_REMOTE_CONTEXT=nodeAddonExamples node --run test:android -- ",
"test:android:nodeTests": "MOCHA_REMOTE_CONTEXT=nodeTests node --run test:android -- ",
"test:android:ferricExample": "MOCHA_REMOTE_CONTEXT=ferricExample node --run test:android -- ",
"test:ios": "mocha-remote --exit-on-error -- concurrently --passthrough-arguments --kill-others-on-fail npm:metro 'npm:ios -- {@}' --",
"test:ios:allTests": "MOCHA_REMOTE_CONTEXT=allTests node --run test:ios -- ",
"test:ios:nodeAddonExamples": "MOCHA_REMOTE_CONTEXT=nodeAddonExamples node --run test:ios -- ",
"test:ios:nodeTests": "MOCHA_REMOTE_CONTEXT=nodeTests node --run test:ios -- ",
"test:ios:ferricExample": "MOCHA_REMOTE_CONTEXT=ferricExample node --run test:ios -- "
},
"dependencies": {
"@babel/core": "^7.26.10",
"@babel/preset-env": "^7.26.9",
"@babel/runtime": "^7.27.0",
"@react-native-community/cli": "^20.0.2",
"@react-native-community/cli-platform-android": "^20.0.2",
"@react-native-community/cli-platform-ios": "^20.0.2",
"@react-native-node-api/node-addon-examples": "workspace:*",
"@react-native-node-api/node-tests": "workspace:*",
"@react-native/babel-preset": "0.81.4",
"@react-native/metro-config": "0.81.4",
"@react-native/typescript-config": "0.81.4",
"@rnx-kit/metro-config": "^2.1.1",
"@types/mocha": "^10.0.10",
"@types/react": "^19.1.0",
"concurrently": "^9.1.2",
"@react-native-node-api/ferric-example": "workspace:*",
"mocha": "^11.6.0",
"mocha-remote-cli": "^1.13.2",
"mocha-remote-react-native": "^1.13.2",
"react": "19.1.0",
"react-native": "0.81.4",
"react-native-node-api": "workspace:*",
"react-native-test-app": "^4.3.3"
}
}
Loading
Loading