Fix key prop in PointsCreator component: add unique key for nested point mapping to improve rendering performance.
This commit is contained in:
parent
4fc014cd28
commit
52c6017649
|
@ -122,7 +122,7 @@ function PointsCreator() {
|
|||
key={i}
|
||||
position={new THREE.Vector3(...event.position)}
|
||||
>
|
||||
{event.points.map((point) => (
|
||||
{event.points.map((point, j) => (
|
||||
<mesh
|
||||
name="Event-Sphere"
|
||||
uuid={point.uuid}
|
||||
|
@ -133,6 +133,7 @@ function PointsCreator() {
|
|||
sphereRefs.current[point.uuid]
|
||||
);
|
||||
}}
|
||||
key={`${i}-${j}`}
|
||||
position={new THREE.Vector3(...point.position)}
|
||||
userData={{
|
||||
modelUuid: event.modelUuid,
|
||||
|
|
Loading…
Reference in New Issue