Skip to content

BacklinkPlugin

Extends

Properties

_children

_children: Component[]

Child Components attached to current component, will be unloaded on unloading parent component

Inherited from

InternalPlugin._children


_events

_events: EventRef[]

Events that are attached to the current component, will be detached on unloading parent component

Inherited from

InternalPlugin._events


_loaded

_loaded: boolean

Whether the component and its children are loaded

Inherited from

InternalPlugin._loaded


addedButtonEls

addedButtonEls: HTMLDivElement[]

Inherited from

InternalPlugin.addedButtonEls


app

app: App

Inherited from

InternalPlugin.app


commands

commands: Command[]

Inherited from

InternalPlugin.commands


enabled

enabled: boolean

Inherited from

InternalPlugin.enabled


hasStatusBarItem

hasStatusBarItem: boolean

Inherited from

InternalPlugin.hasStatusBarItem


instance

instance: BacklinkPluginInstance

Inherited from

InternalPlugin.instance


lastSave

lastSave: number

Inherited from

InternalPlugin.lastSave


manager

manager: InternalPlugins

Inherited from

InternalPlugin.manager


mobileFileInfo

mobileFileInfo: MobileFileInfo[]

Inherited from

InternalPlugin.mobileFileInfo


onConfigFileChange

onConfigFileChange: Debouncer<[], Promise<void>>

Inherited from

InternalPlugin.onConfigFileChange


ribbonItems

ribbonItems: RibbonItem[]

Inherited from

InternalPlugin.ribbonItems


statusBarEl

statusBarEl: null | HTMLDivElement

Inherited from

InternalPlugin.statusBarEl


views

views: object

Parameters

left: WorkspaceLeaf

Returns

BacklinkView

Overrides

InternalPlugin.views

Methods

addChild()

addChild<T>(component): T

Adds a child component, loading it if this component is loaded

Type Parameters

T extends Component

Parameters

component: T

Returns

T

Inherited from

InternalPlugin.addChild


addSettingTab()

addSettingTab(settingTab): void

Parameters

settingTab: PluginSettingTab

Returns

void

Inherited from

InternalPlugin.addSettingTab


deleteData()

deleteData(): Promise<void>

Returns

Promise<void>

Inherited from

InternalPlugin.deleteData


disable()

disable(isDisabledByUser?): void

Parameters

isDisabledByUser?: boolean

Returns

void

Inherited from

InternalPlugin.disable


enable()

enable(isEnabledByUser?): Promise<void>

Parameters

isEnabledByUser?: boolean

Returns

Promise<void>

Inherited from

InternalPlugin.enable


getModifiedTime()

getModifiedTime(): Promise<undefined | number>

Returns

Promise<undefined | number>

Inherited from

InternalPlugin.getModifiedTime


handleConfigFileChange()

handleConfigFileChange(): Promise<void>

Returns

Promise<void>

Inherited from

InternalPlugin.handleConfigFileChange


init()

init(): void

Returns

void

Inherited from

InternalPlugin.init


load()

load(): void

Load this component and its children

Returns

void

Inherited from

InternalPlugin.load


loadData()

loadData(): Promise<null | object>

Returns

Promise<null | object>

Inherited from

InternalPlugin.loadData


onload()

onload(): void

Override this to load your component

Returns

void

Inherited from

InternalPlugin.onload


onunload()

onunload(): void

Override this to unload your component

Returns

void

Inherited from

InternalPlugin.onunload


register()

register(cb): void

Registers a callback to be called when unloading

Parameters

cb

Returns

void

Inherited from

InternalPlugin.register


registerDomEvent()

registerDomEvent(el, type, callback, options)

registerDomEvent<K>(el, type, callback, options?): void

Registers an DOM event to be detached when unloading

Type Parameters

K extends keyof WindowEventMap

Parameters

el: Window

type: K

callback

options?: boolean | AddEventListenerOptions

Returns

void

Inherited from

InternalPlugin.registerDomEvent

registerDomEvent(el, type, callback, options)

registerDomEvent<K>(el, type, callback, options?): void

Registers an DOM event to be detached when unloading

Type Parameters

K extends keyof DocumentEventMap

Parameters

el: Document

type: K

callback

options?: boolean | AddEventListenerOptions

Returns

void

Inherited from

InternalPlugin.registerDomEvent

registerDomEvent(el, type, callback, options)

registerDomEvent<K>(el, type, callback, options?): void

Registers an DOM event to be detached when unloading

Type Parameters

K extends keyof HTMLElementEventMap

Parameters

el: HTMLElement

type: K

callback

options?: boolean | AddEventListenerOptions

Returns

void

Inherited from

InternalPlugin.registerDomEvent


registerEvent()

registerEvent(eventRef): void

Registers an event to be detached when unloading

Parameters

eventRef: EventRef

Returns

void

Inherited from

InternalPlugin.registerEvent


registerGlobalCommand()

registerGlobalCommand(command): void

Parameters

command: Command

Returns

void

Inherited from

InternalPlugin.registerGlobalCommand


registerInterval()

registerInterval(id): number

Registers an interval (from setInterval) to be cancelled when unloading Use setInterval instead of setInterval to avoid TypeScript confusing between NodeJS vs Browser API

Parameters

id: number

Returns

number

Inherited from

InternalPlugin.registerInterval


registerMobileFileInfo()

registerMobileFileInfo(renderCallback): void

Parameters

renderCallback

Returns

void

Inherited from

InternalPlugin.registerMobileFileInfo


registerRibbonItem()

registerRibbonItem(title, icon, callback): void

Parameters

title: string

icon: string

callback

Returns

void

Inherited from

InternalPlugin.registerRibbonItem


registerScopeEvent()

registerScopeEvent(keymapEventHandler): void

Parameters

keymapEventHandler: KeymapEventHandler

Returns

void

Inherited from

InternalPlugin.registerScopeEvent


registerStatusBarItem()

registerStatusBarItem(): void

Returns

void

Inherited from

InternalPlugin.registerStatusBarItem


registerViewType()

registerViewType(type, creator): void

Parameters

type: string

creator: ViewCreator

Returns

void

Inherited from

InternalPlugin.registerViewType


removeChild()

removeChild<T>(component): T

Removes a child component, unloading it

Type Parameters

T extends Component

Parameters

component: T

Returns

T

Inherited from

InternalPlugin.removeChild


saveData()

saveData(data): Promise<void>

Parameters

data: object

Returns

Promise<void>

Inherited from

InternalPlugin.saveData


unload()

unload(): void

Unload this component and its children

Returns

void

Inherited from

InternalPlugin.unload