s-m-r-t
Open the s-m-r-t source on GitHub Switch to dark color scheme
← All UI components

Svelte · Components

Provider

No summary has been written for Provider. Everything below is generated from the declaration shipped in 0.44.0 and describes the real contract.

Public export

typescript
import { Provider } from '@happyvertical/smrt-svelte';
Import path
@happyvertical/smrt-svelte
Props
12
Props described
12 of 12
Bindable state
0
Callback events
3
Verified release
0.44.0

Props

NameTypeRequiredDescription
modeAppModeNoInitial mode: 'default' | 'smrt' If not provided, mode is auto-detected based on capabilities
autoEnableSmrtbooleanNoWhether to auto-enable smrt mode when capabilities are available
userUser | nullNoUser object from smrt-users (from your load function) Pass null when not authenticated
permissionsstring[]NoResolved permissions (from PermissionResolver in your load function)
socketSocketConfigNoWebSocket configuration If provided, connects on mount and disconnects on unmount
aiAIConfigNoAI configuration for preloading and warm clients
onReady() => voidNoCallback when capabilities are detected
onModeChange(mode: AppMode) => voidNoCallback when mode changes
onAILoadingChange(state: AILoadingState) => voidNoCallback when AI loading state changes
i18nI18nSnapshotNoi18n snapshot from your load function (`buildI18nSnapshot` on `@happyvertical/smrt-svelte/i18n/server`). Provides the active locale + resolved message templates to `useI18n()` / `<Trans>`. Omit for English-default-only rendering.
webmcpboolean | WebMcpProviderConfigNoOpt in to generated data tools and the fixed mounted-UI tool adapter for this browser surface. WebMCP is feature-detected, so this is safe during SSR and on browsers that do not expose `document.modelContext`.
childrenSnippetYesChildren to render

Bindable state

This component has no bindable public state.

Callback events

  • onReady() => void
  • onModeChange(mode: AppMode) => void
  • onAILoadingChange(state: AILoadingState) => void

Examples and explanation