Skip to main content

<group>

Used to reference a set of components.

Props

PropTypeDescriptionDefault
positionarrayPosition of group relative to app[0,0,0]
rotationarrayRotation of group relative to app[0,0,0]
scalearrayScale of group[1,1,1]
hitDistancenumberMaximum distance to interact with this node0.5
onHoverEnterfunctionCalled when an avatar hovers over the group. Provides an Eventnull
onHoverLeavefunctionCalled when an avatar hovers over the group. Provides an Eventnull
onPointerDownfunctionCalled when avatar presses the pointer down over this object.null
onPointerDownHintfunctionText displayed when hovering over this object when onPointerDown is defined.null
onPointerUpfunctionCalled when avatar releases the pointer over this object.null
onPointerUpHintfunctionText displayed when hovering over this object with the pointer down and onPointerUp is defined.null

Example

tip

Similar to a <div> but for 3D elements.

const ShapeGroup = () => {
return (
<group position={position} rotation={rotation} scale={scale}>
<Box position={boxOffset} />
<Sphere position={sphereOffset} />
</group>
);
};