目录

Using Inspector Bidirectional Preview

DevEco Studio provides bidirectional preview between the UI preview pages and source code files in .ets format. To enable bidirectional preview, click the icon on the menu bar.

Bidirectional preview is not supported for service widgets.

When this feature is enabled, the code editor, UI, and component tree become interconnected:

With the Previewer, you can modify component attributes or styles on the attribute panel. Saving your modifications will automatically update your source code in the code editor and refresh the UI in real time. Similarly, saving your modifications in source code editor will update the UI, component tree, as well as component attributes in real time.
  • If there is data binding in a component, its attributes cannot be modified from the attribute panel.
  • If a component involves animations, its attributes cannot be modified from the attribute panel.
  • Bidirectional preview is not supported during multi-device preview.