@react-three/fiber 9.0.0-beta.1 → 9.0.0-rc.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +66 -0
- package/dist/declarations/src/core/events.d.ts +91 -0
- package/dist/declarations/src/core/hooks.d.ts +52 -0
- package/dist/declarations/src/core/index.d.ts +13 -0
- package/dist/declarations/src/core/loop.d.ts +31 -0
- package/dist/declarations/src/core/reconciler.d.ts +55 -0
- package/dist/declarations/src/core/renderer.d.ts +87 -0
- package/dist/declarations/src/core/store.d.ts +130 -0
- package/dist/declarations/src/core/utils.d.ts +138 -0
- package/dist/declarations/src/index.d.ts +6 -0
- package/dist/declarations/src/native/Canvas.d.ts +14 -0
- package/dist/declarations/src/native/events.d.ts +4 -0
- package/dist/declarations/src/native.d.ts +6 -0
- package/dist/declarations/src/three-types.d.ts +62 -0
- package/dist/declarations/src/web/Canvas.d.ts +24 -0
- package/dist/declarations/src/web/events.d.ts +4 -0
- package/dist/declarations/src/web/use-measure.d.ts +34 -0
- package/dist/{loop-b00a3b86.esm.js → events-26d2636c.esm.js} +99 -17
- package/dist/{loop-dfcc9ca9.cjs.prod.js → events-cb1a9ea0.cjs.prod.js} +99 -16
- package/dist/{loop-eb3c7218.cjs.dev.js → events-df578889.cjs.dev.js} +99 -16
- package/dist/react-three-fiber.cjs.dev.js +230 -122
- package/dist/react-three-fiber.cjs.prod.js +230 -122
- package/dist/react-three-fiber.esm.js +193 -84
- package/native/dist/react-three-fiber-native.cjs.dev.js +190 -128
- package/native/dist/react-three-fiber-native.cjs.prod.js +190 -128
- package/native/dist/react-three-fiber-native.esm.js +157 -95
- package/package.json +88 -86
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {
|
|
2
|
-
export { t as ReactThreeFiber, _ as _roots,
|
|
1
|
+
import { e as extend, u as useBridge, a as useMutableCallback, c as createRoot, E as ErrorBoundary, B as Block, d as unmountComponentAtNode, f as createPointerEvents, g as createEvents } from '../../dist/events-26d2636c.esm.js';
|
|
2
|
+
export { t as ReactThreeFiber, _ as _roots, x as act, k as addAfterEffect, j as addEffect, l as addTail, n as advance, s as applyProps, y as buildGraph, q as context, g as createEvents, p as createPortal, c as createRoot, w as dispose, e as extend, h as flushGlobalEffects, v as getRootState, m as invalidate, r as reconciler, o as render, d as unmountComponentAtNode, D as useFrame, F as useGraph, z as useInstanceHandle, G as useLoader, A as useStore, C as useThree } from '../../dist/events-26d2636c.esm.js';
|
|
3
3
|
import * as React from 'react';
|
|
4
4
|
import * as THREE from 'three';
|
|
5
5
|
import { PanResponder, PixelRatio, StyleSheet, View, Platform, Image, NativeModules } from 'react-native';
|
|
@@ -12,91 +12,9 @@ import { fromByteArray } from 'base64-js';
|
|
|
12
12
|
import { Buffer } from 'buffer';
|
|
13
13
|
import 'react-reconciler/constants';
|
|
14
14
|
import 'zustand/traditional';
|
|
15
|
+
import 'suspend-react';
|
|
15
16
|
import 'react-reconciler';
|
|
16
17
|
import 'scheduler';
|
|
17
|
-
import 'suspend-react';
|
|
18
|
-
|
|
19
|
-
/** Default R3F event manager for react-native */
|
|
20
|
-
function createTouchEvents(store) {
|
|
21
|
-
const {
|
|
22
|
-
handlePointer
|
|
23
|
-
} = createEvents(store);
|
|
24
|
-
const handleTouch = (event, name) => {
|
|
25
|
-
event.persist()
|
|
26
|
-
|
|
27
|
-
// Apply offset
|
|
28
|
-
;
|
|
29
|
-
event.nativeEvent.offsetX = event.nativeEvent.locationX;
|
|
30
|
-
event.nativeEvent.offsetY = event.nativeEvent.locationY;
|
|
31
|
-
|
|
32
|
-
// Emulate DOM event
|
|
33
|
-
const callback = handlePointer(name);
|
|
34
|
-
callback(event.nativeEvent);
|
|
35
|
-
return true;
|
|
36
|
-
};
|
|
37
|
-
const responder = PanResponder.create({
|
|
38
|
-
onStartShouldSetPanResponder: () => true,
|
|
39
|
-
onMoveShouldSetPanResponder: () => true,
|
|
40
|
-
onMoveShouldSetPanResponderCapture: () => true,
|
|
41
|
-
onPanResponderTerminationRequest: () => true,
|
|
42
|
-
onStartShouldSetPanResponderCapture: e => handleTouch(e, 'onPointerCapture'),
|
|
43
|
-
onPanResponderStart: e => handleTouch(e, 'onPointerDown'),
|
|
44
|
-
onPanResponderMove: e => handleTouch(e, 'onPointerMove'),
|
|
45
|
-
onPanResponderEnd: (e, state) => {
|
|
46
|
-
handleTouch(e, 'onPointerUp');
|
|
47
|
-
if (Math.hypot(state.dx, state.dy) < 20) handleTouch(e, 'onClick');
|
|
48
|
-
},
|
|
49
|
-
onPanResponderRelease: e => handleTouch(e, 'onPointerLeave'),
|
|
50
|
-
onPanResponderTerminate: e => handleTouch(e, 'onLostPointerCapture'),
|
|
51
|
-
onPanResponderReject: e => handleTouch(e, 'onLostPointerCapture')
|
|
52
|
-
});
|
|
53
|
-
return {
|
|
54
|
-
priority: 1,
|
|
55
|
-
enabled: true,
|
|
56
|
-
compute(event, state, previous) {
|
|
57
|
-
// https://github.com/pmndrs/react-three-fiber/pull/782
|
|
58
|
-
// Events trigger outside of canvas when moved, use offsetX/Y by default and allow overrides
|
|
59
|
-
state.pointer.set(event.offsetX / state.size.width * 2 - 1, -(event.offsetY / state.size.height) * 2 + 1);
|
|
60
|
-
state.raycaster.setFromCamera(state.pointer, state.camera);
|
|
61
|
-
},
|
|
62
|
-
connected: undefined,
|
|
63
|
-
handlers: responder.panHandlers,
|
|
64
|
-
update: () => {
|
|
65
|
-
var _internal$lastEvent;
|
|
66
|
-
const {
|
|
67
|
-
events,
|
|
68
|
-
internal
|
|
69
|
-
} = store.getState();
|
|
70
|
-
if ((_internal$lastEvent = internal.lastEvent) != null && _internal$lastEvent.current && events.handlers) {
|
|
71
|
-
handlePointer('onPointerMove')(internal.lastEvent.current);
|
|
72
|
-
}
|
|
73
|
-
},
|
|
74
|
-
connect: () => {
|
|
75
|
-
const {
|
|
76
|
-
set,
|
|
77
|
-
events
|
|
78
|
-
} = store.getState();
|
|
79
|
-
events.disconnect == null ? void 0 : events.disconnect();
|
|
80
|
-
set(state => ({
|
|
81
|
-
events: {
|
|
82
|
-
...state.events,
|
|
83
|
-
connected: true
|
|
84
|
-
}
|
|
85
|
-
}));
|
|
86
|
-
},
|
|
87
|
-
disconnect: () => {
|
|
88
|
-
const {
|
|
89
|
-
set
|
|
90
|
-
} = store.getState();
|
|
91
|
-
set(state => ({
|
|
92
|
-
events: {
|
|
93
|
-
...state.events,
|
|
94
|
-
connected: false
|
|
95
|
-
}
|
|
96
|
-
}));
|
|
97
|
-
}
|
|
98
|
-
};
|
|
99
|
-
}
|
|
100
18
|
|
|
101
19
|
// TODO: React 19 needs support from react-native
|
|
102
20
|
const _View = View;
|
|
@@ -108,7 +26,7 @@ const CanvasImpl = /*#__PURE__*/React.forwardRef(({
|
|
|
108
26
|
children,
|
|
109
27
|
style,
|
|
110
28
|
gl,
|
|
111
|
-
events =
|
|
29
|
+
events = createPointerEvents,
|
|
112
30
|
shadows,
|
|
113
31
|
linear,
|
|
114
32
|
flat,
|
|
@@ -171,22 +89,87 @@ const CanvasImpl = /*#__PURE__*/React.forwardRef(({
|
|
|
171
89
|
// Called on context create or swap
|
|
172
90
|
// https://github.com/pmndrs/react-three-fiber/pull/2297
|
|
173
91
|
const onContextCreate = React.useCallback(context => {
|
|
174
|
-
const
|
|
92
|
+
const listeners = new Map();
|
|
93
|
+
const canvas = {
|
|
94
|
+
style: {},
|
|
175
95
|
width: context.drawingBufferWidth,
|
|
176
96
|
height: context.drawingBufferHeight,
|
|
177
|
-
|
|
178
|
-
addEventListener: () => {},
|
|
179
|
-
removeEventListener: () => {},
|
|
97
|
+
clientWidth: context.drawingBufferWidth,
|
|
180
98
|
clientHeight: context.drawingBufferHeight,
|
|
181
99
|
getContext: (_, {
|
|
182
100
|
antialias = false
|
|
183
101
|
}) => {
|
|
184
102
|
setAntialias(antialias);
|
|
185
103
|
return context;
|
|
104
|
+
},
|
|
105
|
+
addEventListener(type, listener) {
|
|
106
|
+
let callbacks = listeners.get(type);
|
|
107
|
+
if (!callbacks) {
|
|
108
|
+
callbacks = [];
|
|
109
|
+
listeners.set(type, callbacks);
|
|
110
|
+
}
|
|
111
|
+
callbacks.push(listener);
|
|
112
|
+
},
|
|
113
|
+
removeEventListener(type, listener) {
|
|
114
|
+
const callbacks = listeners.get(type);
|
|
115
|
+
if (callbacks) {
|
|
116
|
+
const index = callbacks.indexOf(listener);
|
|
117
|
+
if (index !== -1) callbacks.splice(index, 1);
|
|
118
|
+
}
|
|
119
|
+
},
|
|
120
|
+
dispatchEvent(event) {
|
|
121
|
+
Object.assign(event, {
|
|
122
|
+
target: this
|
|
123
|
+
});
|
|
124
|
+
const callbacks = listeners.get(event.type);
|
|
125
|
+
if (callbacks) {
|
|
126
|
+
for (const callback of callbacks) {
|
|
127
|
+
callback(event);
|
|
128
|
+
}
|
|
129
|
+
}
|
|
130
|
+
},
|
|
131
|
+
setPointerCapture() {
|
|
132
|
+
// TODO
|
|
133
|
+
},
|
|
134
|
+
releasePointerCapture() {
|
|
135
|
+
// TODO
|
|
186
136
|
}
|
|
187
137
|
};
|
|
188
|
-
|
|
189
|
-
|
|
138
|
+
|
|
139
|
+
// TODO: this is wrong but necessary to trick controls
|
|
140
|
+
// @ts-ignore
|
|
141
|
+
canvas.ownerDocument = canvas;
|
|
142
|
+
canvas.getRootNode = () => canvas;
|
|
143
|
+
root.current = createRoot(canvas);
|
|
144
|
+
setCanvas(canvas);
|
|
145
|
+
function handleTouch(gestureEvent, type) {
|
|
146
|
+
gestureEvent.persist();
|
|
147
|
+
canvas.dispatchEvent(Object.assign(gestureEvent.nativeEvent, {
|
|
148
|
+
type,
|
|
149
|
+
offsetX: gestureEvent.nativeEvent.locationX,
|
|
150
|
+
offsetY: gestureEvent.nativeEvent.locationY,
|
|
151
|
+
pointerType: 'touch',
|
|
152
|
+
pointerId: gestureEvent.nativeEvent.identifier
|
|
153
|
+
}));
|
|
154
|
+
return true;
|
|
155
|
+
}
|
|
156
|
+
const responder = PanResponder.create({
|
|
157
|
+
onStartShouldSetPanResponder: () => true,
|
|
158
|
+
onMoveShouldSetPanResponder: () => true,
|
|
159
|
+
onMoveShouldSetPanResponderCapture: () => true,
|
|
160
|
+
onPanResponderTerminationRequest: () => true,
|
|
161
|
+
onStartShouldSetPanResponderCapture: e => handleTouch(e, 'pointercapture'),
|
|
162
|
+
onPanResponderStart: e => handleTouch(e, 'pointerdown'),
|
|
163
|
+
onPanResponderMove: e => handleTouch(e, 'pointermove'),
|
|
164
|
+
onPanResponderEnd: (e, state) => {
|
|
165
|
+
handleTouch(e, 'pointerup');
|
|
166
|
+
if (Math.hypot(state.dx, state.dy) < 20) handleTouch(e, 'click');
|
|
167
|
+
},
|
|
168
|
+
onPanResponderRelease: e => handleTouch(e, 'pointerleave'),
|
|
169
|
+
onPanResponderTerminate: e => handleTouch(e, 'lostpointercapture'),
|
|
170
|
+
onPanResponderReject: e => handleTouch(e, 'lostpointercapture')
|
|
171
|
+
});
|
|
172
|
+
setBind(responder.panHandlers);
|
|
190
173
|
}, []);
|
|
191
174
|
if (root.current && width > 0 && height > 0) {
|
|
192
175
|
root.current.configure({
|
|
@@ -215,9 +198,6 @@ const CanvasImpl = /*#__PURE__*/React.forwardRef(({
|
|
|
215
198
|
onPointerMissed: (...args) => handlePointerMissed.current == null ? void 0 : handlePointerMissed.current(...args),
|
|
216
199
|
// Overwrite onCreated to apply RN bindings
|
|
217
200
|
onCreated: state => {
|
|
218
|
-
// Bind events after creation
|
|
219
|
-
setBind(state.events.handlers);
|
|
220
|
-
|
|
221
201
|
// Bind render to RN bridge
|
|
222
202
|
const context = state.gl.getContext();
|
|
223
203
|
const renderFrame = state.gl.render.bind(state.gl);
|
|
@@ -275,6 +255,88 @@ const Canvas = /*#__PURE__*/React.forwardRef(function CanvasWrapper(props, ref)
|
|
|
275
255
|
});
|
|
276
256
|
});
|
|
277
257
|
|
|
258
|
+
/** Default R3F event manager for react-native */
|
|
259
|
+
function createTouchEvents(store) {
|
|
260
|
+
const {
|
|
261
|
+
handlePointer
|
|
262
|
+
} = createEvents(store);
|
|
263
|
+
const handleTouch = (event, name) => {
|
|
264
|
+
event.persist()
|
|
265
|
+
|
|
266
|
+
// Apply offset
|
|
267
|
+
;
|
|
268
|
+
event.nativeEvent.offsetX = event.nativeEvent.locationX;
|
|
269
|
+
event.nativeEvent.offsetY = event.nativeEvent.locationY;
|
|
270
|
+
|
|
271
|
+
// Emulate DOM event
|
|
272
|
+
const callback = handlePointer(name);
|
|
273
|
+
callback(event.nativeEvent);
|
|
274
|
+
return true;
|
|
275
|
+
};
|
|
276
|
+
const responder = PanResponder.create({
|
|
277
|
+
onStartShouldSetPanResponder: () => true,
|
|
278
|
+
onMoveShouldSetPanResponder: () => true,
|
|
279
|
+
onMoveShouldSetPanResponderCapture: () => true,
|
|
280
|
+
onPanResponderTerminationRequest: () => true,
|
|
281
|
+
onStartShouldSetPanResponderCapture: e => handleTouch(e, 'onPointerCapture'),
|
|
282
|
+
onPanResponderStart: e => handleTouch(e, 'onPointerDown'),
|
|
283
|
+
onPanResponderMove: e => handleTouch(e, 'onPointerMove'),
|
|
284
|
+
onPanResponderEnd: (e, state) => {
|
|
285
|
+
handleTouch(e, 'onPointerUp');
|
|
286
|
+
if (Math.hypot(state.dx, state.dy) < 20) handleTouch(e, 'onClick');
|
|
287
|
+
},
|
|
288
|
+
onPanResponderRelease: e => handleTouch(e, 'onPointerLeave'),
|
|
289
|
+
onPanResponderTerminate: e => handleTouch(e, 'onLostPointerCapture'),
|
|
290
|
+
onPanResponderReject: e => handleTouch(e, 'onLostPointerCapture')
|
|
291
|
+
});
|
|
292
|
+
return {
|
|
293
|
+
priority: 1,
|
|
294
|
+
enabled: true,
|
|
295
|
+
compute(event, state, previous) {
|
|
296
|
+
// https://github.com/pmndrs/react-three-fiber/pull/782
|
|
297
|
+
// Events trigger outside of canvas when moved, use offsetX/Y by default and allow overrides
|
|
298
|
+
state.pointer.set(event.offsetX / state.size.width * 2 - 1, -(event.offsetY / state.size.height) * 2 + 1);
|
|
299
|
+
state.raycaster.setFromCamera(state.pointer, state.camera);
|
|
300
|
+
},
|
|
301
|
+
connected: undefined,
|
|
302
|
+
handlers: responder.panHandlers,
|
|
303
|
+
update: () => {
|
|
304
|
+
var _internal$lastEvent;
|
|
305
|
+
const {
|
|
306
|
+
events,
|
|
307
|
+
internal
|
|
308
|
+
} = store.getState();
|
|
309
|
+
if ((_internal$lastEvent = internal.lastEvent) != null && _internal$lastEvent.current && events.handlers) {
|
|
310
|
+
handlePointer('onPointerMove')(internal.lastEvent.current);
|
|
311
|
+
}
|
|
312
|
+
},
|
|
313
|
+
connect: () => {
|
|
314
|
+
const {
|
|
315
|
+
set,
|
|
316
|
+
events
|
|
317
|
+
} = store.getState();
|
|
318
|
+
events.disconnect == null ? void 0 : events.disconnect();
|
|
319
|
+
set(state => ({
|
|
320
|
+
events: {
|
|
321
|
+
...state.events,
|
|
322
|
+
connected: true
|
|
323
|
+
}
|
|
324
|
+
}));
|
|
325
|
+
},
|
|
326
|
+
disconnect: () => {
|
|
327
|
+
const {
|
|
328
|
+
set
|
|
329
|
+
} = store.getState();
|
|
330
|
+
set(state => ({
|
|
331
|
+
events: {
|
|
332
|
+
...state.events,
|
|
333
|
+
connected: false
|
|
334
|
+
}
|
|
335
|
+
}));
|
|
336
|
+
}
|
|
337
|
+
};
|
|
338
|
+
}
|
|
339
|
+
|
|
278
340
|
// http://stackoverflow.com/questions/105034
|
|
279
341
|
function uuidv4() {
|
|
280
342
|
return 'xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx'.replace(/[xy]/g, c => {
|
package/package.json
CHANGED
|
@@ -1,86 +1,88 @@
|
|
|
1
|
-
{
|
|
2
|
-
"name": "@react-three/fiber",
|
|
3
|
-
"version": "9.0.0-
|
|
4
|
-
"description": "A React renderer for Threejs",
|
|
5
|
-
"keywords": [
|
|
6
|
-
"react",
|
|
7
|
-
"renderer",
|
|
8
|
-
"fiber",
|
|
9
|
-
"three",
|
|
10
|
-
"threejs"
|
|
11
|
-
],
|
|
12
|
-
"author": "Paul Henschel (https://github.com/drcmda)",
|
|
13
|
-
"license": "MIT",
|
|
14
|
-
"maintainers": [
|
|
15
|
-
"Josh Ellis (https://github.com/joshuaellis)",
|
|
16
|
-
"Cody Bennett (https://github.com/codyjasonbennett)"
|
|
17
|
-
],
|
|
18
|
-
"bugs": {
|
|
19
|
-
"url": "https://github.com/pmndrs/react-three-fiber/issues"
|
|
20
|
-
},
|
|
21
|
-
"homepage": "https://github.com/pmndrs/react-three-fiber#readme",
|
|
22
|
-
"repository": {
|
|
23
|
-
"type": "git",
|
|
24
|
-
"url": "git+https://github.com/pmndrs/react-three-fiber.git"
|
|
25
|
-
},
|
|
26
|
-
"collective": {
|
|
27
|
-
"type": "opencollective",
|
|
28
|
-
"url": "https://opencollective.com/react-three-fiber"
|
|
29
|
-
},
|
|
30
|
-
"main": "dist/react-three-fiber.cjs.js",
|
|
31
|
-
"module": "dist/react-three-fiber.esm.js",
|
|
32
|
-
"types": "dist/react-three-fiber.cjs.d.ts",
|
|
33
|
-
"react-native": "native/dist/react-three-fiber-native.cjs.js",
|
|
34
|
-
"sideEffects": false,
|
|
35
|
-
"preconstruct": {
|
|
36
|
-
"entrypoints": [
|
|
37
|
-
"index.tsx",
|
|
38
|
-
"native.tsx"
|
|
39
|
-
]
|
|
40
|
-
},
|
|
41
|
-
"scripts": {
|
|
42
|
-
"prebuild": "cp ../../readme.md readme.md"
|
|
43
|
-
},
|
|
44
|
-
"dependencies": {
|
|
45
|
-
"@babel/runtime": "^7.17.8",
|
|
46
|
-
"@types/
|
|
47
|
-
"
|
|
48
|
-
"
|
|
49
|
-
"
|
|
50
|
-
"
|
|
51
|
-
"
|
|
52
|
-
"
|
|
53
|
-
"
|
|
54
|
-
"
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
"expo
|
|
60
|
-
"expo-
|
|
61
|
-
"
|
|
62
|
-
"
|
|
63
|
-
"react
|
|
64
|
-
"
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
}
|
|
1
|
+
{
|
|
2
|
+
"name": "@react-three/fiber",
|
|
3
|
+
"version": "9.0.0-rc.1",
|
|
4
|
+
"description": "A React renderer for Threejs",
|
|
5
|
+
"keywords": [
|
|
6
|
+
"react",
|
|
7
|
+
"renderer",
|
|
8
|
+
"fiber",
|
|
9
|
+
"three",
|
|
10
|
+
"threejs"
|
|
11
|
+
],
|
|
12
|
+
"author": "Paul Henschel (https://github.com/drcmda)",
|
|
13
|
+
"license": "MIT",
|
|
14
|
+
"maintainers": [
|
|
15
|
+
"Josh Ellis (https://github.com/joshuaellis)",
|
|
16
|
+
"Cody Bennett (https://github.com/codyjasonbennett)"
|
|
17
|
+
],
|
|
18
|
+
"bugs": {
|
|
19
|
+
"url": "https://github.com/pmndrs/react-three-fiber/issues"
|
|
20
|
+
},
|
|
21
|
+
"homepage": "https://github.com/pmndrs/react-three-fiber#readme",
|
|
22
|
+
"repository": {
|
|
23
|
+
"type": "git",
|
|
24
|
+
"url": "git+https://github.com/pmndrs/react-three-fiber.git"
|
|
25
|
+
},
|
|
26
|
+
"collective": {
|
|
27
|
+
"type": "opencollective",
|
|
28
|
+
"url": "https://opencollective.com/react-three-fiber"
|
|
29
|
+
},
|
|
30
|
+
"main": "dist/react-three-fiber.cjs.js",
|
|
31
|
+
"module": "dist/react-three-fiber.esm.js",
|
|
32
|
+
"types": "dist/react-three-fiber.cjs.d.ts",
|
|
33
|
+
"react-native": "native/dist/react-three-fiber-native.cjs.js",
|
|
34
|
+
"sideEffects": false,
|
|
35
|
+
"preconstruct": {
|
|
36
|
+
"entrypoints": [
|
|
37
|
+
"index.tsx",
|
|
38
|
+
"native.tsx"
|
|
39
|
+
]
|
|
40
|
+
},
|
|
41
|
+
"scripts": {
|
|
42
|
+
"prebuild": "cp ../../readme.md readme.md"
|
|
43
|
+
},
|
|
44
|
+
"dependencies": {
|
|
45
|
+
"@babel/runtime": "^7.17.8",
|
|
46
|
+
"@types/debounce": "^1.2.1",
|
|
47
|
+
"@types/react-reconciler": "^0.28.8",
|
|
48
|
+
"@types/webxr": "*",
|
|
49
|
+
"base64-js": "^1.5.1",
|
|
50
|
+
"buffer": "^6.0.3",
|
|
51
|
+
"debounce": "^1.2.1",
|
|
52
|
+
"its-fine": "^1.2.5",
|
|
53
|
+
"react-reconciler": "0.31.0-rc.1",
|
|
54
|
+
"scheduler": "0.25.0-rc.1",
|
|
55
|
+
"suspend-react": "^0.1.3",
|
|
56
|
+
"zustand": "^4.1.2"
|
|
57
|
+
},
|
|
58
|
+
"peerDependencies": {
|
|
59
|
+
"expo": ">=43.0",
|
|
60
|
+
"expo-asset": ">=8.4",
|
|
61
|
+
"expo-gl": ">=11.0",
|
|
62
|
+
"expo-file-system": ">=11.0",
|
|
63
|
+
"react": ">=19.0",
|
|
64
|
+
"react-dom": ">=19.0",
|
|
65
|
+
"react-native": ">=0.69",
|
|
66
|
+
"three": ">=0.141"
|
|
67
|
+
},
|
|
68
|
+
"peerDependenciesMeta": {
|
|
69
|
+
"react-dom": {
|
|
70
|
+
"optional": true
|
|
71
|
+
},
|
|
72
|
+
"react-native": {
|
|
73
|
+
"optional": true
|
|
74
|
+
},
|
|
75
|
+
"expo": {
|
|
76
|
+
"optional": true
|
|
77
|
+
},
|
|
78
|
+
"expo-asset": {
|
|
79
|
+
"optional": true
|
|
80
|
+
},
|
|
81
|
+
"expo-file-system": {
|
|
82
|
+
"optional": true
|
|
83
|
+
},
|
|
84
|
+
"expo-gl": {
|
|
85
|
+
"optional": true
|
|
86
|
+
}
|
|
87
|
+
}
|
|
88
|
+
}
|