Skip to content

Commit 6bbed57

Browse files
authored
chore(🐙): minor housekeeping (#285)
1 parent 76c7699 commit 6bbed57

File tree

3 files changed

+20
-17
lines changed

3 files changed

+20
-17
lines changed

.github/workflows/ci.yml

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,20 @@ on:
99
merge_group:
1010
types:
1111
- checks_requested
12+
workflow_dispatch:
13+
inputs:
14+
build_android:
15+
description: 'Build for Android'
16+
type: boolean
17+
default: false
18+
build_ios:
19+
description: 'Build for iOS'
20+
type: boolean
21+
default: false
22+
build_macos:
23+
description: 'Build for macOS'
24+
type: boolean
25+
default: false
1226

1327
concurrency:
1428
group: ${{ github.ref }}

README.md

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,8 @@
11
# React Native WebGPU
22

33
React Native implementation of WebGPU using [Dawn](https://dawn.googlesource.com/dawn).
4-
This is currently a technical preview for early adopters.
54

6-
React Native WebGPU requires React Native 0.81 or newer and doesn't run on legacy architecture.
5+
React Native WebGPU requires React Native 0.81 or newer. It doesn't support the legacy architecture.
76

87
## Installation
98

packages/webgpu/README.md

Lines changed: 5 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,8 @@
11
# React Native WebGPU
22

3-
React Native implementation of WebGPU using [Dawn](https://dawn.googlesource.com/dawn).
4-
This is currently a technical preview for early adopters.
3+
React Native implementation of WebGPU using [Dawn](https://dawn.googlesource.com/dawn).
54

6-
React Native WebGPU requires React Native 0.81 or newer and doesn't run on legacy architecture.
5+
React Native WebGPU requires React Native 0.81 or newer. It doesn't support the legacy architecture.
76

87
## Installation
98

@@ -13,8 +12,6 @@ Please note that the package name is `react-native-wgpu`.
1312
npm install react-native-wgpu
1413
```
1514

16-
Note that if you use pnpm, you MUST use a `node-linker = hoisted` so that the external reference to the Dawn webgpu library can successfully link it.
17-
1815
Below are some examples from the [example app](/apps/example/).
1916

2017
https://github.com/user-attachments/assets/116a41b2-2cf8-49f1-9f16-a5c83637c198
@@ -38,13 +35,6 @@ We also provide prebuilt binaries for visionOS and macOS.
3835

3936
https://github.com/user-attachments/assets/2d5c618e-5b15-4cef-8558-d4ddf8c70667
4037

41-
## Diagnostics
42-
43-
Two diagnostic screens were added to the example app so you can reproduce the issues highlighted in the code review:
44-
45-
- `Async Runner Starvation` (`apps/example/src/Diagnostics/AsyncStarvation.tsx`) shows that a zero-delay `setTimeout` never fires before `device.createRenderPipelineAsync()` resolves because the event loop is kept busy. Launch the example app and open the screen from the home list to observe the stalled timer.
46-
- `Device Lost Promise Hang` (`apps/example/src/Diagnostics/DeviceLostHang.tsx`) forces a synthetic device loss by calling the native `forceLossForTesting()` helper. On the current build the `device.lost` promise remains pending indefinitely, confirming that the loss callback is never delivered once pumping stops.
47-
4838
## Usage
4939

5040
Usage is identical to Web.
@@ -158,8 +148,8 @@ From there you will be able to run the example app properly.
158148

159149
## Similarities and Differences with the Web
160150

161-
The API has been designed to be completely symmetric with the Web.
162-
For instance, you can access the WebGPU context synchronously, as well as the canvas size.
151+
The API has been designed to be completely symmetric with the Web.
152+
For instance, you can access the WebGPU context synchronously, as well as the canvas size.
163153
Pixel density and canvas resizing are handled exactly like on the Web as well.
164154

165155
```tsx
@@ -173,7 +163,7 @@ ctx.canvas.height = ctx.canvas.clientHeight * PixelRatio.get();
173163

174164
### Frame Scheduling
175165

176-
In React Native, we want to keep frame presentation as a manual operation as we plan to provide more advanced rendering options that are React Native specific.
166+
In React Native, we want to keep frame presentation as a manual operation as we plan to provide more advanced rendering options that are React Native specific.
177167
This means that when you are ready to present a frame, you need to call `present` on the context.
178168

179169
```tsx

0 commit comments

Comments
 (0)