Skip to content

DailyNotesPluginInstance

Unofficial

Plugin instance for daily notes, providing date-based note creation and navigation.

Import:

import type { DailyNotesPluginInstance } from '@obsidian-typings/obsidian-catalyst-latest';

Signature:

export interface DailyNotesPluginInstance extends InternalPluginInstance<DailyNotesPlugin>

Extends: InternalPluginInstance<DailyNotesPlugin>

Properties

PropertyTypeDescription
appAppReference to the app.
defaultOntrueWhether this plugin is enabled by default.
descriptionstringHuman-readable description of this plugin.
(Inherited from InternalPluginInstance)
idstringUnique identifier for this plugin.
(Inherited from InternalPluginInstance)
namestringHuman-readable display name of this plugin.
(Inherited from InternalPluginInstance)
optionsDailyNotesOptionsConfiguration options for daily notes.
pluginDailyNotesPluginReference to the daily notes plugin registration.

Methods

MethodReturnsDescription
getCurrentFileDateTimestamp()null | numberGet the date timestamp from the currently open file name, or null if not a daily note.
getDailyNote(date)Promise<null | TFile | undefined>Get or create the daily note for the given date.
getFormat()stringGet the configured date format string for daily note filenames.
gotoNextExisting(timestamp)Promise<void>Navigate to the next existing daily note after the given timestamp.
gotoPreviousExisting(timestamp)Promise<void>Navigate to the previous existing daily note before the given timestamp.
init(app, plugin)voidInitialize the plugin instance with app and plugin references.
(Inherited from InternalPluginInstance)
iterateDailyNotes(callback)voidIterate over all daily notes in the vault, invoking the callback for each.
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)
onExternalSettingsChange()Promise<void>Handle external settings file changes and reload configuration.
onOpenDailyNote(evt)Promise<void>Handle the open daily note command event.
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)

Links to this page: