Skip to content

App

Defined in: context.svelte.ts:200

Central runtime service container exposed to plugins, views, and renderer integrations.

App owns the active vault session, workspace layout, plugin runtime, commands, metadata cache, notifications, and related shared services.

new App(props): App

Defined in: context.svelte.ts:261

Create the application service container for a mounted vault session.

AppStateProperties

Runtime services and adapters required to bootstrap the app.

App

readonly appDatabase: AppDatabase

Defined in: context.svelte.ts:204


commands: CommandManager

Defined in: context.svelte.ts:229


readonly configuration: Configuration

Defined in: context.svelte.ts:213


readonly configurationOptionSources: ConfigurationOptionSourceRegistry

Defined in: context.svelte.ts:234


readonly contextKeys: ContextKeyService

Defined in: context.svelte.ts:215


readonly editors: Map<string, Set<ExtType>>

Defined in: context.svelte.ts:211


readonly editorSuggest: Map<string, Set<EditorSuggest<any>>>

Defined in: context.svelte.ts:212


embedRegistry: EmbedRegistry

Defined in: context.svelte.ts:233


readonly fileManager: FileManager

Defined in: context.svelte.ts:214


readonly i18n: LocalizationManager = localeManager

Defined in: context.svelte.ts:201


keymap: Keymap

Defined in: context.svelte.ts:209


readonly languageServices: LanguageServiceManager

Defined in: context.svelte.ts:240


lastEvent: UserEvent | null

Defined in: context.svelte.ts:235


readonly logger: Logger

Defined in: context.svelte.ts:253


mardownCodeBlockPostProcessor: Record<string, MarkdownPostProcessor[]>

Defined in: context.svelte.ts:222


mardownPostProcessor: MarkdownPostProcessor[]

Defined in: context.svelte.ts:221


markdownDirectiveRenderers: Record<string, MarkdownDirectiveRenderer>

Defined in: context.svelte.ts:224


readonly markdownViewMenuItems: Set<MarkdownViewMenuItemProvider>

Defined in: context.svelte.ts:226


metadataCache: MetadataCache

Defined in: context.svelte.ts:232


metadataTypeManager: MetadataTypeManager

Defined in: context.svelte.ts:227


notifications: NotificationManager

Defined in: context.svelte.ts:238


readonly pluginDistribution: DefaultPluginDistributionManager

Defined in: context.svelte.ts:219


plugins: PluginManager

Defined in: context.svelte.ts:207


readonly props: AppStateProperties

Defined in: context.svelte.ts:261

Runtime services and adapters required to bootstrap the app.


renderContext: RenderContext

Defined in: context.svelte.ts:236


readonly safeMode: AppSafeModeState

Defined in: context.svelte.ts:206


scope: Scope

Defined in: context.svelte.ts:208


secretStorage: SecretStorage

Defined in: context.svelte.ts:237


readonly optional session?: VaultSession

Defined in: context.svelte.ts:205


readonly settings: AppSettings

Defined in: context.svelte.ts:210


settingsOpen: boolean

Defined in: context.svelte.ts:230


settingsTabId: string | null

Defined in: context.svelte.ts:231


readonly statusBar: StatusBarManager

Defined in: context.svelte.ts:216


telemetry: TelemetryService

Defined in: context.svelte.ts:239


readonly urls: AppUrlService

Defined in: context.svelte.ts:217


readonly vault: Vault

Defined in: context.svelte.ts:203


readonly workspace: Workspace

Defined in: context.svelte.ts:202


readonly workspaceTrust: WorkspaceTrustService

Defined in: context.svelte.ts:218

get internalPlugins(): object

Defined in: context.svelte.ts:249

object

getEnabledPluginById: (pluginId) => any

string

any

plugins: Record<string, { manifest: PluginManifest; }>


get isDarkMode(): boolean

Defined in: context.svelte.ts:596

boolean


get version(): string

Defined in: context.svelte.ts:592

string

editorExtensions(viewType, context?): Extension[]

Defined in: context.svelte.ts:461

string

Record<string, any> = {}

Extension[]


emulateMobile(enable?): Promise<void>

Defined in: context.svelte.ts:618

Force mobile or desktop workspace layout and reload the app.

Intended for devtools/console use when testing mobile shell behavior on desktop viewports.

boolean = true

When true or omitted, forces mobile layout; when false, forces desktop layout.

Promise<void>


loadLocalStorage(key): string | null

Defined in: context.svelte.ts:600

string

string | null


openFile(file, openState?): Promise<void>

Defined in: context.svelte.ts:414

TFile

OpenViewState

Promise<void>


registerEditorExtension(extension, viewType?): void

Defined in: context.svelte.ts:489

Registers a CodeMirror 6 extension. To reconfigure cm6 extensions for a plugin on the fly, an array should be passed in, and modified dynamically. Once this array is modified, calling Workspace#updateOptions will apply the changes.

ExtType

Must be a CodeMirror 6 Extension, or an array of Extensions.

string = "markdown"

void


registerEditorSuggest(suggest, viewType?): void

Defined in: context.svelte.ts:508

EditorSuggest<any>

string = "markdown"

void


registerMarkdownCodeBlockProcessor(language, postProcessor): void

Defined in: context.svelte.ts:542

string

MarkdownPostProcessor

void


registerMarkdownDirectiveRenderer(directive, renderer): void

Defined in: context.svelte.ts:569

string

MarkdownDirectiveRenderer

void


registerMarkdownPostProcessor(postProcessor): void

Defined in: context.svelte.ts:527

MarkdownPostProcessor

void


registerMarkdownViewMenuItem(provider): void

Defined in: context.svelte.ts:584

MarkdownViewMenuItemProvider

void


saveLocalStorage(key, data): void

Defined in: context.svelte.ts:604

string

string

void


setting(id): SettingGroup

Defined in: context.svelte.ts:628

"options" | "core-plugins" | "community-plugins"

SettingGroup


setWorkspaceTrusted(trusted): void

Defined in: context.svelte.ts:410

boolean

void


unregisterEditorExtension(extension, viewType?): void

Defined in: context.svelte.ts:500

ExtType

string = "markdown"

void


unregisterEditorSuggest(suggest, viewType?): void

Defined in: context.svelte.ts:519

EditorSuggest<any>

string = "markdown"

void


unregisterMarkdownCodeBlockProcessor(language, postProcessor): void

Defined in: context.svelte.ts:558

string

MarkdownPostProcessor

void


unregisterMarkdownDirectiveRenderer(directive): void

Defined in: context.svelte.ts:579

string

void


unregisterMarkdownPostProcessor(postProcessor): void

Defined in: context.svelte.ts:536

MarkdownPostProcessor

void


unregisterMarkdownViewMenuItem(provider): void

Defined in: context.svelte.ts:588

MarkdownViewMenuItemProvider

void