Skip to main content
New Participant
October 9, 2026
Question

Setting "properties" on IWSDK UIKit

  • October 9, 2026
  • 2 replies
  • 37 views

https://iwsdk.dev/guides/10-spatial-ui-uikitml.html describes how to statically set up UI using .uikitml files and how to add event listeners, but does not document how to change "properties" of UIKit objects. These "properties" are documented somewhat at https://pmndrs.github.io/uikit/docs/getting-started/components-and-properties  These "properties" are not JavaScript properties. There is an undocumented setProperties({prop: value}) method to set these "properties", but no getProperty() or getProperties() methods.

Is setting UIKit "properties" documented anywhere?

2 replies

RumBerberAuthor
New Participant
October 9, 2026

Or to put it more generally, is there documentation on using UIKit dynamically via JavaScript/TypeScript?

RumBerberAuthor
New Participant
October 12, 2026

This code runs without error, but nothing is visible:
 

        const tutorialAsset = this.world.getSceneObject<UIKitMLAsset>('tutorial');       
// @ts-ignore
const root = tutorialAsset.document // UKKitDocument (root)
const panel = new Container({ flexDirection: 'row', gap: 8 });
panel.setProperties({width: 300, height: 300});
panel.position.set(0, 1.5, -1);
panel.add(new Text({ text: 'Hello XR' }));
root.add(panel);