Skip to content

PublishPluginInstance

Unofficial

Plugin instance for Obsidian Publish, managing cloud publishing of vault content.

Import:

import type { PublishPluginInstance } from '@obsidian-typings/obsidian-public-latest';

Signature:

export interface PublishPluginInstance extends InternalPluginInstance<PublishPlugin>

Extends: InternalPluginInstance<PublishPlugin>

Properties

PropertyTypeDescription
appAppReference to the app.
descriptionstringHuman-readable description of this plugin.
(Inherited from InternalPluginInstance)
idstringUnique identifier for this plugin.
(Inherited from InternalPluginInstance)
modalnull | PublishModalThe Publish changes dialog, null until it is first opened.
namestringHuman-readable display name of this plugin.
(Inherited from InternalPluginInstance)
pluginPublishPluginReference to the publish plugin registration.
siteIdnull | stringThe id of the site the vault publishes to, null when none is set up.

Methods

MethodReturnsDescription
getCurrentSlug()Promise<string>Get the slug of the current site.
init(app, plugin)voidInitialize the plugin instance with app and plugin references.
(Inherited from InternalPluginInstance)
onDisable(app, plugin)voidCalled when the plugin is disabled.
(Inherited from InternalPluginInstance)
onEnable(app, plugin)Promise<void>Called when the plugin is enabled.
(Inherited from InternalPluginInstance)
onUserDisable(app)voidCalled when the user manually disables the plugin.
(Inherited from InternalPluginInstance)
onUserEnable(app)voidCalled when the user manually enables the plugin.
(Inherited from InternalPluginInstance)
openModal(getSection?)voidOpen the Publish changes dialog, creating it on first use.

Links to this page: