Host Integration
For embedded apps, prefer mode: "inherit" so MLForm follows host light or dark surfaces.
mountForm(container, { transport: createJsonTransport({ endpoint: "/api/predict" }), schema, designSystem: { mode: "inherit", theme: "neutral", recipe: "minimal", },});Use onDesignSystemChange to inspect the resolved system:
mountForm(container, { transport: createJsonTransport({ endpoint: "/api/predict" }), schema, onDesignSystemChange(resolved) { console.log(resolved.effectiveScheme, resolved.themeId, resolved.recipeId); },});The mounted handle also exposes updateDesignSystem, replaceDesignSystem, and resetDesignSystem.