pub fn open_widget(
widget_id: String,
surface: Option<String>,
runtime: State<'_, Runtime>,
) -> Result<WidgetHostSession, String>Expand description
Starts a session for a widget surface: main, settings, dashboard, or module.
Frame surfaces get the manifest’s permissions. Module sessions get every permission because modules run in the app window. Fails in safe mode and for disabled widgets.