@react-three/fiber 9.3.0 → 9.4.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 +12 -0
- package/dist/{events-d0449b76.cjs.dev.js → events-1d578043.cjs.dev.js} +134 -16
- package/dist/{events-e3cb66e2.esm.js → events-2487ec62.esm.js} +134 -16
- package/dist/{events-d0a20a9c.cjs.prod.js → events-af6d715d.cjs.prod.js} +134 -16
- package/dist/react-three-fiber.cjs.dev.js +1 -1
- package/dist/react-three-fiber.cjs.prod.js +1 -1
- package/dist/react-three-fiber.esm.js +2 -2
- package/native/dist/react-three-fiber-native.cjs.dev.js +1 -1
- package/native/dist/react-three-fiber-native.cjs.prod.js +1 -1
- package/native/dist/react-three-fiber-native.esm.js +2 -2
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,17 @@
|
|
|
1
1
|
# @react-three/fiber
|
|
2
2
|
|
|
3
|
+
## 9.4.1
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- 4f8cec0d79003a9ef6d1ca1e56de94aec4158714: fix: pass DevTools config through createReconciler to fix React DevTools
|
|
8
|
+
|
|
9
|
+
## 9.4.0
|
|
10
|
+
|
|
11
|
+
### Minor Changes
|
|
12
|
+
|
|
13
|
+
- f0976dc14a2d3203af267d0e3524d45a07f3248a: feat: improve applyProps errors, harden pierced props setting
|
|
14
|
+
|
|
3
15
|
## 9.3.0
|
|
4
16
|
|
|
5
17
|
### Minor Changes
|
|
@@ -241,24 +241,46 @@ function prepare(target, root, type, props) {
|
|
|
241
241
|
return instance;
|
|
242
242
|
}
|
|
243
243
|
function resolve(root, key) {
|
|
244
|
-
let target = root[key];
|
|
245
244
|
if (!key.includes('-')) return {
|
|
246
245
|
root,
|
|
247
246
|
key,
|
|
248
|
-
target
|
|
247
|
+
target: root[key]
|
|
249
248
|
};
|
|
250
249
|
|
|
251
|
-
//
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
250
|
+
// First try the entire key as a single property (e.g., 'foo-bar')
|
|
251
|
+
if (key in root) {
|
|
252
|
+
return {
|
|
253
|
+
root,
|
|
254
|
+
key,
|
|
255
|
+
target: root[key]
|
|
256
|
+
};
|
|
257
|
+
}
|
|
258
|
+
|
|
259
|
+
// Try piercing (e.g., 'material-color' -> material.color)
|
|
260
|
+
let target = root;
|
|
261
|
+
const parts = key.split('-');
|
|
262
|
+
for (const part of parts) {
|
|
263
|
+
if (typeof target !== 'object' || target === null) {
|
|
264
|
+
if (target !== undefined) {
|
|
265
|
+
// Property exists but has unexpected shape
|
|
266
|
+
const remaining = parts.slice(parts.indexOf(part)).join('-');
|
|
267
|
+
return {
|
|
268
|
+
root: target,
|
|
269
|
+
key: remaining,
|
|
270
|
+
target: undefined
|
|
271
|
+
};
|
|
272
|
+
}
|
|
273
|
+
// Property doesn't exist - fallback to original key
|
|
274
|
+
return {
|
|
275
|
+
root,
|
|
276
|
+
key,
|
|
277
|
+
target: undefined
|
|
278
|
+
};
|
|
279
|
+
}
|
|
255
280
|
key = part;
|
|
256
281
|
root = target;
|
|
257
|
-
target =
|
|
282
|
+
target = target[key];
|
|
258
283
|
}
|
|
259
|
-
|
|
260
|
-
// TODO: change key to 'foo-bar' if target is undefined?
|
|
261
|
-
|
|
262
284
|
return {
|
|
263
285
|
root,
|
|
264
286
|
key,
|
|
@@ -401,6 +423,11 @@ function applyProps(object, props) {
|
|
|
401
423
|
target
|
|
402
424
|
} = resolve(object, prop);
|
|
403
425
|
|
|
426
|
+
// Throw an error if we attempted to set a pierced prop to a non-object
|
|
427
|
+
if (target === undefined && (typeof root !== 'object' || root === null)) {
|
|
428
|
+
throw Error(`R3F: Cannot set "${prop}". Ensure it is an object before setting "${key}".`);
|
|
429
|
+
}
|
|
430
|
+
|
|
404
431
|
// Layers must be written to the mask property
|
|
405
432
|
if (target instanceof THREE__namespace.Layers && value instanceof THREE__namespace.Layers) {
|
|
406
433
|
target.mask = value.mask;
|
|
@@ -1256,13 +1283,101 @@ useLoader.clear = function (loader, input) {
|
|
|
1256
1283
|
return suspendReact.clear([loader, ...keys]);
|
|
1257
1284
|
};
|
|
1258
1285
|
|
|
1286
|
+
var packageData = {
|
|
1287
|
+
name: "@react-three/fiber",
|
|
1288
|
+
version: "9.4.1",
|
|
1289
|
+
description: "A React renderer for Threejs",
|
|
1290
|
+
keywords: [
|
|
1291
|
+
"react",
|
|
1292
|
+
"renderer",
|
|
1293
|
+
"fiber",
|
|
1294
|
+
"three",
|
|
1295
|
+
"threejs"
|
|
1296
|
+
],
|
|
1297
|
+
author: "Paul Henschel (https://github.com/drcmda)",
|
|
1298
|
+
license: "MIT",
|
|
1299
|
+
maintainers: [
|
|
1300
|
+
"Josh Ellis (https://github.com/joshuaellis)",
|
|
1301
|
+
"Cody Bennett (https://github.com/codyjasonbennett)",
|
|
1302
|
+
"Kris Baumgarter (https://github.com/krispya)"
|
|
1303
|
+
],
|
|
1304
|
+
bugs: {
|
|
1305
|
+
url: "https://github.com/pmndrs/react-three-fiber/issues"
|
|
1306
|
+
},
|
|
1307
|
+
homepage: "https://github.com/pmndrs/react-three-fiber#readme",
|
|
1308
|
+
repository: {
|
|
1309
|
+
type: "git",
|
|
1310
|
+
url: "git+https://github.com/pmndrs/react-three-fiber.git"
|
|
1311
|
+
},
|
|
1312
|
+
collective: {
|
|
1313
|
+
type: "opencollective",
|
|
1314
|
+
url: "https://opencollective.com/react-three-fiber"
|
|
1315
|
+
},
|
|
1316
|
+
main: "dist/react-three-fiber.cjs.js",
|
|
1317
|
+
module: "dist/react-three-fiber.esm.js",
|
|
1318
|
+
types: "dist/react-three-fiber.cjs.d.ts",
|
|
1319
|
+
"react-native": "native/dist/react-three-fiber-native.cjs.js",
|
|
1320
|
+
sideEffects: false,
|
|
1321
|
+
preconstruct: {
|
|
1322
|
+
entrypoints: [
|
|
1323
|
+
"index.tsx",
|
|
1324
|
+
"native.tsx"
|
|
1325
|
+
]
|
|
1326
|
+
},
|
|
1327
|
+
scripts: {
|
|
1328
|
+
prebuild: "cp ../../readme.md readme.md"
|
|
1329
|
+
},
|
|
1330
|
+
dependencies: {
|
|
1331
|
+
"@babel/runtime": "^7.17.8",
|
|
1332
|
+
"@types/react-reconciler": "^0.32.0",
|
|
1333
|
+
"@types/webxr": "*",
|
|
1334
|
+
"base64-js": "^1.5.1",
|
|
1335
|
+
buffer: "^6.0.3",
|
|
1336
|
+
"its-fine": "^2.0.0",
|
|
1337
|
+
"react-reconciler": "^0.31.0",
|
|
1338
|
+
"react-use-measure": "^2.1.7",
|
|
1339
|
+
scheduler: "^0.25.0",
|
|
1340
|
+
"suspend-react": "^0.1.3",
|
|
1341
|
+
"use-sync-external-store": "^1.4.0",
|
|
1342
|
+
zustand: "^5.0.3"
|
|
1343
|
+
},
|
|
1344
|
+
peerDependencies: {
|
|
1345
|
+
expo: ">=43.0",
|
|
1346
|
+
"expo-asset": ">=8.4",
|
|
1347
|
+
"expo-file-system": ">=11.0",
|
|
1348
|
+
"expo-gl": ">=11.0",
|
|
1349
|
+
react: "^19.0.0",
|
|
1350
|
+
"react-dom": "^19.0.0",
|
|
1351
|
+
"react-native": ">=0.78",
|
|
1352
|
+
three: ">=0.156"
|
|
1353
|
+
},
|
|
1354
|
+
peerDependenciesMeta: {
|
|
1355
|
+
"react-dom": {
|
|
1356
|
+
optional: true
|
|
1357
|
+
},
|
|
1358
|
+
"react-native": {
|
|
1359
|
+
optional: true
|
|
1360
|
+
},
|
|
1361
|
+
expo: {
|
|
1362
|
+
optional: true
|
|
1363
|
+
},
|
|
1364
|
+
"expo-asset": {
|
|
1365
|
+
optional: true
|
|
1366
|
+
},
|
|
1367
|
+
"expo-file-system": {
|
|
1368
|
+
optional: true
|
|
1369
|
+
},
|
|
1370
|
+
"expo-gl": {
|
|
1371
|
+
optional: true
|
|
1372
|
+
}
|
|
1373
|
+
}
|
|
1374
|
+
};
|
|
1375
|
+
|
|
1259
1376
|
function createReconciler(config) {
|
|
1260
1377
|
const reconciler = Reconciler__default["default"](config);
|
|
1261
|
-
|
|
1262
|
-
|
|
1263
|
-
|
|
1264
|
-
version: React__namespace.version
|
|
1265
|
-
});
|
|
1378
|
+
|
|
1379
|
+
// @ts-ignore DefinitelyTyped is not up to date
|
|
1380
|
+
reconciler.injectIntoDevTools();
|
|
1266
1381
|
return reconciler;
|
|
1267
1382
|
}
|
|
1268
1383
|
const NoEventPriority = 0;
|
|
@@ -1684,7 +1799,10 @@ const reconciler = /* @__PURE__ */createReconciler({
|
|
|
1684
1799
|
return constants.DefaultEventPriority;
|
|
1685
1800
|
}
|
|
1686
1801
|
},
|
|
1687
|
-
resetFormInstance() {}
|
|
1802
|
+
resetFormInstance() {},
|
|
1803
|
+
// @ts-ignore DefinitelyTyped is not up to date
|
|
1804
|
+
rendererPackageName: '@react-three/fiber',
|
|
1805
|
+
rendererVersion: packageData.version
|
|
1688
1806
|
});
|
|
1689
1807
|
|
|
1690
1808
|
const _roots = new Map();
|
|
@@ -215,24 +215,46 @@ function prepare(target, root, type, props) {
|
|
|
215
215
|
return instance;
|
|
216
216
|
}
|
|
217
217
|
function resolve(root, key) {
|
|
218
|
-
let target = root[key];
|
|
219
218
|
if (!key.includes('-')) return {
|
|
220
219
|
root,
|
|
221
220
|
key,
|
|
222
|
-
target
|
|
221
|
+
target: root[key]
|
|
223
222
|
};
|
|
224
223
|
|
|
225
|
-
//
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
224
|
+
// First try the entire key as a single property (e.g., 'foo-bar')
|
|
225
|
+
if (key in root) {
|
|
226
|
+
return {
|
|
227
|
+
root,
|
|
228
|
+
key,
|
|
229
|
+
target: root[key]
|
|
230
|
+
};
|
|
231
|
+
}
|
|
232
|
+
|
|
233
|
+
// Try piercing (e.g., 'material-color' -> material.color)
|
|
234
|
+
let target = root;
|
|
235
|
+
const parts = key.split('-');
|
|
236
|
+
for (const part of parts) {
|
|
237
|
+
if (typeof target !== 'object' || target === null) {
|
|
238
|
+
if (target !== undefined) {
|
|
239
|
+
// Property exists but has unexpected shape
|
|
240
|
+
const remaining = parts.slice(parts.indexOf(part)).join('-');
|
|
241
|
+
return {
|
|
242
|
+
root: target,
|
|
243
|
+
key: remaining,
|
|
244
|
+
target: undefined
|
|
245
|
+
};
|
|
246
|
+
}
|
|
247
|
+
// Property doesn't exist - fallback to original key
|
|
248
|
+
return {
|
|
249
|
+
root,
|
|
250
|
+
key,
|
|
251
|
+
target: undefined
|
|
252
|
+
};
|
|
253
|
+
}
|
|
229
254
|
key = part;
|
|
230
255
|
root = target;
|
|
231
|
-
target =
|
|
256
|
+
target = target[key];
|
|
232
257
|
}
|
|
233
|
-
|
|
234
|
-
// TODO: change key to 'foo-bar' if target is undefined?
|
|
235
|
-
|
|
236
258
|
return {
|
|
237
259
|
root,
|
|
238
260
|
key,
|
|
@@ -375,6 +397,11 @@ function applyProps(object, props) {
|
|
|
375
397
|
target
|
|
376
398
|
} = resolve(object, prop);
|
|
377
399
|
|
|
400
|
+
// Throw an error if we attempted to set a pierced prop to a non-object
|
|
401
|
+
if (target === undefined && (typeof root !== 'object' || root === null)) {
|
|
402
|
+
throw Error(`R3F: Cannot set "${prop}". Ensure it is an object before setting "${key}".`);
|
|
403
|
+
}
|
|
404
|
+
|
|
378
405
|
// Layers must be written to the mask property
|
|
379
406
|
if (target instanceof THREE.Layers && value instanceof THREE.Layers) {
|
|
380
407
|
target.mask = value.mask;
|
|
@@ -1230,13 +1257,101 @@ useLoader.clear = function (loader, input) {
|
|
|
1230
1257
|
return clear([loader, ...keys]);
|
|
1231
1258
|
};
|
|
1232
1259
|
|
|
1260
|
+
var packageData = {
|
|
1261
|
+
name: "@react-three/fiber",
|
|
1262
|
+
version: "9.4.1",
|
|
1263
|
+
description: "A React renderer for Threejs",
|
|
1264
|
+
keywords: [
|
|
1265
|
+
"react",
|
|
1266
|
+
"renderer",
|
|
1267
|
+
"fiber",
|
|
1268
|
+
"three",
|
|
1269
|
+
"threejs"
|
|
1270
|
+
],
|
|
1271
|
+
author: "Paul Henschel (https://github.com/drcmda)",
|
|
1272
|
+
license: "MIT",
|
|
1273
|
+
maintainers: [
|
|
1274
|
+
"Josh Ellis (https://github.com/joshuaellis)",
|
|
1275
|
+
"Cody Bennett (https://github.com/codyjasonbennett)",
|
|
1276
|
+
"Kris Baumgarter (https://github.com/krispya)"
|
|
1277
|
+
],
|
|
1278
|
+
bugs: {
|
|
1279
|
+
url: "https://github.com/pmndrs/react-three-fiber/issues"
|
|
1280
|
+
},
|
|
1281
|
+
homepage: "https://github.com/pmndrs/react-three-fiber#readme",
|
|
1282
|
+
repository: {
|
|
1283
|
+
type: "git",
|
|
1284
|
+
url: "git+https://github.com/pmndrs/react-three-fiber.git"
|
|
1285
|
+
},
|
|
1286
|
+
collective: {
|
|
1287
|
+
type: "opencollective",
|
|
1288
|
+
url: "https://opencollective.com/react-three-fiber"
|
|
1289
|
+
},
|
|
1290
|
+
main: "dist/react-three-fiber.cjs.js",
|
|
1291
|
+
module: "dist/react-three-fiber.esm.js",
|
|
1292
|
+
types: "dist/react-three-fiber.cjs.d.ts",
|
|
1293
|
+
"react-native": "native/dist/react-three-fiber-native.cjs.js",
|
|
1294
|
+
sideEffects: false,
|
|
1295
|
+
preconstruct: {
|
|
1296
|
+
entrypoints: [
|
|
1297
|
+
"index.tsx",
|
|
1298
|
+
"native.tsx"
|
|
1299
|
+
]
|
|
1300
|
+
},
|
|
1301
|
+
scripts: {
|
|
1302
|
+
prebuild: "cp ../../readme.md readme.md"
|
|
1303
|
+
},
|
|
1304
|
+
dependencies: {
|
|
1305
|
+
"@babel/runtime": "^7.17.8",
|
|
1306
|
+
"@types/react-reconciler": "^0.32.0",
|
|
1307
|
+
"@types/webxr": "*",
|
|
1308
|
+
"base64-js": "^1.5.1",
|
|
1309
|
+
buffer: "^6.0.3",
|
|
1310
|
+
"its-fine": "^2.0.0",
|
|
1311
|
+
"react-reconciler": "^0.31.0",
|
|
1312
|
+
"react-use-measure": "^2.1.7",
|
|
1313
|
+
scheduler: "^0.25.0",
|
|
1314
|
+
"suspend-react": "^0.1.3",
|
|
1315
|
+
"use-sync-external-store": "^1.4.0",
|
|
1316
|
+
zustand: "^5.0.3"
|
|
1317
|
+
},
|
|
1318
|
+
peerDependencies: {
|
|
1319
|
+
expo: ">=43.0",
|
|
1320
|
+
"expo-asset": ">=8.4",
|
|
1321
|
+
"expo-file-system": ">=11.0",
|
|
1322
|
+
"expo-gl": ">=11.0",
|
|
1323
|
+
react: "^19.0.0",
|
|
1324
|
+
"react-dom": "^19.0.0",
|
|
1325
|
+
"react-native": ">=0.78",
|
|
1326
|
+
three: ">=0.156"
|
|
1327
|
+
},
|
|
1328
|
+
peerDependenciesMeta: {
|
|
1329
|
+
"react-dom": {
|
|
1330
|
+
optional: true
|
|
1331
|
+
},
|
|
1332
|
+
"react-native": {
|
|
1333
|
+
optional: true
|
|
1334
|
+
},
|
|
1335
|
+
expo: {
|
|
1336
|
+
optional: true
|
|
1337
|
+
},
|
|
1338
|
+
"expo-asset": {
|
|
1339
|
+
optional: true
|
|
1340
|
+
},
|
|
1341
|
+
"expo-file-system": {
|
|
1342
|
+
optional: true
|
|
1343
|
+
},
|
|
1344
|
+
"expo-gl": {
|
|
1345
|
+
optional: true
|
|
1346
|
+
}
|
|
1347
|
+
}
|
|
1348
|
+
};
|
|
1349
|
+
|
|
1233
1350
|
function createReconciler(config) {
|
|
1234
1351
|
const reconciler = Reconciler(config);
|
|
1235
|
-
|
|
1236
|
-
|
|
1237
|
-
|
|
1238
|
-
version: React.version
|
|
1239
|
-
});
|
|
1352
|
+
|
|
1353
|
+
// @ts-ignore DefinitelyTyped is not up to date
|
|
1354
|
+
reconciler.injectIntoDevTools();
|
|
1240
1355
|
return reconciler;
|
|
1241
1356
|
}
|
|
1242
1357
|
const NoEventPriority = 0;
|
|
@@ -1658,7 +1773,10 @@ const reconciler = /* @__PURE__ */createReconciler({
|
|
|
1658
1773
|
return DefaultEventPriority;
|
|
1659
1774
|
}
|
|
1660
1775
|
},
|
|
1661
|
-
resetFormInstance() {}
|
|
1776
|
+
resetFormInstance() {},
|
|
1777
|
+
// @ts-ignore DefinitelyTyped is not up to date
|
|
1778
|
+
rendererPackageName: '@react-three/fiber',
|
|
1779
|
+
rendererVersion: packageData.version
|
|
1662
1780
|
});
|
|
1663
1781
|
|
|
1664
1782
|
const _roots = new Map();
|
|
@@ -241,24 +241,46 @@ function prepare(target, root, type, props) {
|
|
|
241
241
|
return instance;
|
|
242
242
|
}
|
|
243
243
|
function resolve(root, key) {
|
|
244
|
-
let target = root[key];
|
|
245
244
|
if (!key.includes('-')) return {
|
|
246
245
|
root,
|
|
247
246
|
key,
|
|
248
|
-
target
|
|
247
|
+
target: root[key]
|
|
249
248
|
};
|
|
250
249
|
|
|
251
|
-
//
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
250
|
+
// First try the entire key as a single property (e.g., 'foo-bar')
|
|
251
|
+
if (key in root) {
|
|
252
|
+
return {
|
|
253
|
+
root,
|
|
254
|
+
key,
|
|
255
|
+
target: root[key]
|
|
256
|
+
};
|
|
257
|
+
}
|
|
258
|
+
|
|
259
|
+
// Try piercing (e.g., 'material-color' -> material.color)
|
|
260
|
+
let target = root;
|
|
261
|
+
const parts = key.split('-');
|
|
262
|
+
for (const part of parts) {
|
|
263
|
+
if (typeof target !== 'object' || target === null) {
|
|
264
|
+
if (target !== undefined) {
|
|
265
|
+
// Property exists but has unexpected shape
|
|
266
|
+
const remaining = parts.slice(parts.indexOf(part)).join('-');
|
|
267
|
+
return {
|
|
268
|
+
root: target,
|
|
269
|
+
key: remaining,
|
|
270
|
+
target: undefined
|
|
271
|
+
};
|
|
272
|
+
}
|
|
273
|
+
// Property doesn't exist - fallback to original key
|
|
274
|
+
return {
|
|
275
|
+
root,
|
|
276
|
+
key,
|
|
277
|
+
target: undefined
|
|
278
|
+
};
|
|
279
|
+
}
|
|
255
280
|
key = part;
|
|
256
281
|
root = target;
|
|
257
|
-
target =
|
|
282
|
+
target = target[key];
|
|
258
283
|
}
|
|
259
|
-
|
|
260
|
-
// TODO: change key to 'foo-bar' if target is undefined?
|
|
261
|
-
|
|
262
284
|
return {
|
|
263
285
|
root,
|
|
264
286
|
key,
|
|
@@ -401,6 +423,11 @@ function applyProps(object, props) {
|
|
|
401
423
|
target
|
|
402
424
|
} = resolve(object, prop);
|
|
403
425
|
|
|
426
|
+
// Throw an error if we attempted to set a pierced prop to a non-object
|
|
427
|
+
if (target === undefined && (typeof root !== 'object' || root === null)) {
|
|
428
|
+
throw Error(`R3F: Cannot set "${prop}". Ensure it is an object before setting "${key}".`);
|
|
429
|
+
}
|
|
430
|
+
|
|
404
431
|
// Layers must be written to the mask property
|
|
405
432
|
if (target instanceof THREE__namespace.Layers && value instanceof THREE__namespace.Layers) {
|
|
406
433
|
target.mask = value.mask;
|
|
@@ -1256,13 +1283,101 @@ useLoader.clear = function (loader, input) {
|
|
|
1256
1283
|
return suspendReact.clear([loader, ...keys]);
|
|
1257
1284
|
};
|
|
1258
1285
|
|
|
1286
|
+
var packageData = {
|
|
1287
|
+
name: "@react-three/fiber",
|
|
1288
|
+
version: "9.4.1",
|
|
1289
|
+
description: "A React renderer for Threejs",
|
|
1290
|
+
keywords: [
|
|
1291
|
+
"react",
|
|
1292
|
+
"renderer",
|
|
1293
|
+
"fiber",
|
|
1294
|
+
"three",
|
|
1295
|
+
"threejs"
|
|
1296
|
+
],
|
|
1297
|
+
author: "Paul Henschel (https://github.com/drcmda)",
|
|
1298
|
+
license: "MIT",
|
|
1299
|
+
maintainers: [
|
|
1300
|
+
"Josh Ellis (https://github.com/joshuaellis)",
|
|
1301
|
+
"Cody Bennett (https://github.com/codyjasonbennett)",
|
|
1302
|
+
"Kris Baumgarter (https://github.com/krispya)"
|
|
1303
|
+
],
|
|
1304
|
+
bugs: {
|
|
1305
|
+
url: "https://github.com/pmndrs/react-three-fiber/issues"
|
|
1306
|
+
},
|
|
1307
|
+
homepage: "https://github.com/pmndrs/react-three-fiber#readme",
|
|
1308
|
+
repository: {
|
|
1309
|
+
type: "git",
|
|
1310
|
+
url: "git+https://github.com/pmndrs/react-three-fiber.git"
|
|
1311
|
+
},
|
|
1312
|
+
collective: {
|
|
1313
|
+
type: "opencollective",
|
|
1314
|
+
url: "https://opencollective.com/react-three-fiber"
|
|
1315
|
+
},
|
|
1316
|
+
main: "dist/react-three-fiber.cjs.js",
|
|
1317
|
+
module: "dist/react-three-fiber.esm.js",
|
|
1318
|
+
types: "dist/react-three-fiber.cjs.d.ts",
|
|
1319
|
+
"react-native": "native/dist/react-three-fiber-native.cjs.js",
|
|
1320
|
+
sideEffects: false,
|
|
1321
|
+
preconstruct: {
|
|
1322
|
+
entrypoints: [
|
|
1323
|
+
"index.tsx",
|
|
1324
|
+
"native.tsx"
|
|
1325
|
+
]
|
|
1326
|
+
},
|
|
1327
|
+
scripts: {
|
|
1328
|
+
prebuild: "cp ../../readme.md readme.md"
|
|
1329
|
+
},
|
|
1330
|
+
dependencies: {
|
|
1331
|
+
"@babel/runtime": "^7.17.8",
|
|
1332
|
+
"@types/react-reconciler": "^0.32.0",
|
|
1333
|
+
"@types/webxr": "*",
|
|
1334
|
+
"base64-js": "^1.5.1",
|
|
1335
|
+
buffer: "^6.0.3",
|
|
1336
|
+
"its-fine": "^2.0.0",
|
|
1337
|
+
"react-reconciler": "^0.31.0",
|
|
1338
|
+
"react-use-measure": "^2.1.7",
|
|
1339
|
+
scheduler: "^0.25.0",
|
|
1340
|
+
"suspend-react": "^0.1.3",
|
|
1341
|
+
"use-sync-external-store": "^1.4.0",
|
|
1342
|
+
zustand: "^5.0.3"
|
|
1343
|
+
},
|
|
1344
|
+
peerDependencies: {
|
|
1345
|
+
expo: ">=43.0",
|
|
1346
|
+
"expo-asset": ">=8.4",
|
|
1347
|
+
"expo-file-system": ">=11.0",
|
|
1348
|
+
"expo-gl": ">=11.0",
|
|
1349
|
+
react: "^19.0.0",
|
|
1350
|
+
"react-dom": "^19.0.0",
|
|
1351
|
+
"react-native": ">=0.78",
|
|
1352
|
+
three: ">=0.156"
|
|
1353
|
+
},
|
|
1354
|
+
peerDependenciesMeta: {
|
|
1355
|
+
"react-dom": {
|
|
1356
|
+
optional: true
|
|
1357
|
+
},
|
|
1358
|
+
"react-native": {
|
|
1359
|
+
optional: true
|
|
1360
|
+
},
|
|
1361
|
+
expo: {
|
|
1362
|
+
optional: true
|
|
1363
|
+
},
|
|
1364
|
+
"expo-asset": {
|
|
1365
|
+
optional: true
|
|
1366
|
+
},
|
|
1367
|
+
"expo-file-system": {
|
|
1368
|
+
optional: true
|
|
1369
|
+
},
|
|
1370
|
+
"expo-gl": {
|
|
1371
|
+
optional: true
|
|
1372
|
+
}
|
|
1373
|
+
}
|
|
1374
|
+
};
|
|
1375
|
+
|
|
1259
1376
|
function createReconciler(config) {
|
|
1260
1377
|
const reconciler = Reconciler__default["default"](config);
|
|
1261
|
-
|
|
1262
|
-
|
|
1263
|
-
|
|
1264
|
-
version: React__namespace.version
|
|
1265
|
-
});
|
|
1378
|
+
|
|
1379
|
+
// @ts-ignore DefinitelyTyped is not up to date
|
|
1380
|
+
reconciler.injectIntoDevTools();
|
|
1266
1381
|
return reconciler;
|
|
1267
1382
|
}
|
|
1268
1383
|
const NoEventPriority = 0;
|
|
@@ -1684,7 +1799,10 @@ const reconciler = /* @__PURE__ */createReconciler({
|
|
|
1684
1799
|
return constants.DefaultEventPriority;
|
|
1685
1800
|
}
|
|
1686
1801
|
},
|
|
1687
|
-
resetFormInstance() {}
|
|
1802
|
+
resetFormInstance() {},
|
|
1803
|
+
// @ts-ignore DefinitelyTyped is not up to date
|
|
1804
|
+
rendererPackageName: '@react-three/fiber',
|
|
1805
|
+
rendererVersion: packageData.version
|
|
1688
1806
|
});
|
|
1689
1807
|
|
|
1690
1808
|
const _roots = new Map();
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
var events = require('./events-
|
|
5
|
+
var events = require('./events-1d578043.cjs.dev.js');
|
|
6
6
|
var React = require('react');
|
|
7
7
|
var THREE = require('three');
|
|
8
8
|
var useMeasure = require('react-use-measure');
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
var events = require('./events-
|
|
5
|
+
var events = require('./events-af6d715d.cjs.prod.js');
|
|
6
6
|
var React = require('react');
|
|
7
7
|
var THREE = require('three');
|
|
8
8
|
var useMeasure = require('react-use-measure');
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { e as extend, u as useBridge, a as useMutableCallback, b as useIsomorphicLayoutEffect, c as createRoot, i as isRef, E as ErrorBoundary, B as Block, d as unmountComponentAtNode, f as createPointerEvents } from './events-
|
|
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, o as createPortal, c as createRoot, w as dispose, f as events, e as extend, h as flushGlobalEffects, p as flushSync, v as getRootState, m as invalidate, r as reconciler, d as unmountComponentAtNode, D as useFrame, F as useGraph, z as useInstanceHandle, G as useLoader, A as useStore, C as useThree } from './events-
|
|
1
|
+
import { e as extend, u as useBridge, a as useMutableCallback, b as useIsomorphicLayoutEffect, c as createRoot, i as isRef, E as ErrorBoundary, B as Block, d as unmountComponentAtNode, f as createPointerEvents } from './events-2487ec62.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, o as createPortal, c as createRoot, w as dispose, f as events, e as extend, h as flushGlobalEffects, p as flushSync, v as getRootState, m as invalidate, r as reconciler, d as unmountComponentAtNode, D as useFrame, F as useGraph, z as useInstanceHandle, G as useLoader, A as useStore, C as useThree } from './events-2487ec62.esm.js';
|
|
3
3
|
import * as React from 'react';
|
|
4
4
|
import * as THREE from 'three';
|
|
5
5
|
import useMeasure from 'react-use-measure';
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
var events = require('../../dist/events-
|
|
5
|
+
var events = require('../../dist/events-1d578043.cjs.dev.js');
|
|
6
6
|
var React = require('react');
|
|
7
7
|
var THREE = require('three');
|
|
8
8
|
var reactNative = require('react-native');
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
var events = require('../../dist/events-
|
|
5
|
+
var events = require('../../dist/events-af6d715d.cjs.prod.js');
|
|
6
6
|
var React = require('react');
|
|
7
7
|
var THREE = require('three');
|
|
8
8
|
var reactNative = require('react-native');
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { e as extend, u as useBridge, a as useMutableCallback, c as createRoot, b as useIsomorphicLayoutEffect, E as ErrorBoundary, B as Block, d as unmountComponentAtNode, f as createPointerEvents, g as createEvents } from '../../dist/events-
|
|
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, o as createPortal, c as createRoot, w as dispose, e as extend, h as flushGlobalEffects, p as flushSync, v as getRootState, m as invalidate, r as reconciler, d as unmountComponentAtNode, D as useFrame, F as useGraph, z as useInstanceHandle, G as useLoader, A as useStore, C as useThree } from '../../dist/events-
|
|
1
|
+
import { e as extend, u as useBridge, a as useMutableCallback, c as createRoot, b as useIsomorphicLayoutEffect, E as ErrorBoundary, B as Block, d as unmountComponentAtNode, f as createPointerEvents, g as createEvents } from '../../dist/events-2487ec62.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, o as createPortal, c as createRoot, w as dispose, e as extend, h as flushGlobalEffects, p as flushSync, v as getRootState, m as invalidate, r as reconciler, d as unmountComponentAtNode, D as useFrame, F as useGraph, z as useInstanceHandle, G as useLoader, A as useStore, C as useThree } from '../../dist/events-2487ec62.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';
|