There may not be a corresponding package version for every version listed below.
Version History
v1.7.2 (Insider)
v1.7.2 (Insider)
Workspace Changes
New Plugin Lifecycle HookPlugin#onUserEnable- Provides a place to perform one-time initialization after the user installs and enables your plugin. If your plugin has a custom view, this is a good place to initialize it rather than recreating the view inPlugin#onload.
Workspace#ensureSideLeafis now public. This function is a shorthand way to create a leaf in the sidebar if one does not already exist.
- Added
WorkspaceLeaf#isDeferredandWorkspaceLeaf#loadIfDeferred - As of Obsidian v1.7.2, Obsidian will now defer tabs by default
- See the guide on handling deferred views
Breaking Changes
Migration GuideIf your plugin uses the old fuzzy search functions, migrate toprepareFuzzySearch:New Features
Plugin#removeCommand- Dynamically remove commands (useful for user-created commands)SuggestModal#selectActiveSuggestionis now public - Useful for providing alternative hotkeys to your SuggestModal
v1.7.0 (Insider)
v1.7.0 (Insider)
- Fixed
FileSystemAdapter#rmdir(dirPath, false)always throwing an error when attempting to delete an empty directory - Added a
data-typeto the Markdown embed container using subpath type
v1.5.11
v1.5.11
v1.5.7
v1.5.7
External Settings Change Callback
New:Plugin#onExternalSettingsChangeThis callback function allows plugins to react when plugin settings (data.json) are changed on disk. Use this to reload settings when they are updated by an external application or synced using a file syncing service like Obsidian Sync.New Vault Utility Functions
Vault#getFileByPath and Vault#getFolderByPathThe getAbstractFileByPath has long been a point of confusion. More often than not, you are looking for either a file or a folder, and you know which you want at call-time.View Scope Now Public
View.scope is now public. This means you can assign hotkeys for when your view is active and focused.New Utilities
getFrontMatterInfo- Canonical way to find the offsets of where the frontmatter ends and where the content starts in a fileFileManager#getAvailablePathForAttachment- If your plugin saves attachments to the vault, use this to generate a safe path that respects the user’s settings for file attachments
v1.4.4
v1.4.4
v1.4.0
v1.4.0
v1.1.3
v1.1.3
Canvas Spec Update
Updated the Canvas spec to indicate that colors can be stored in 2 formats:- As a hex string (e.g.,
"#FFFFFF") - As a number
"1","2", etc.
Theme Changes
New CSS variables related to canvas and callouts. All extended palette colors now have an RGB variant used for callouts and canvas colors.v1.1.1 (Insider)
v1.1.1 (Insider)
Canvas Integration
file-openevent is now fired when focusing a Canvas file card- Exposed
activeEditoron the Workspace. When a markdown view is active, this will point to the underlyingMarkdownEditView. If a canvas view is active, this will be an EmbeddedEditor component.
Migration Guide
Plugins should now useactiveEditor instead of directly accessing MarkdownView:v1.1.0 (Insider)
v1.1.0 (Insider)
New Metadata API
In anticipation of improvements to metadata and frontmatter, a new metadata API was introduced:Improvements
setTooltipnow accepts an optional tooltip positioneditorCallbackno longer passes the activeview: MarkdownView. Instead, it now provides either the MarkdownView or a MarkdownFileInfo object. This change allows for editor commands to work within a Canvas.registerHoverLinkSourceis now available to register your plugin’s view with the Page preview core plugin
Bug Fixes
- Fixed
Editor.replaceSelectionnot working when run immediately after closing a modal
Notable Changes
- Added support for optional
fundingUrlfield in the plugin manifest. This is a link for users who want to donate to show appreciation and support plugin development. - Added macOS calendar entitlements. This allows scripts run from within Obsidian to request calendar access.
v1.0
v1.0
New Components
- Added standard color picker component
Improvements
getLeafcan now be used to create a leaf in a new tab, a new tab group, or a new window- Preferred usage:
getLeaf(Keymap.isModEvent(evt))whereevtis the user’s KeyboardEvent. This allows for a consistent user experience when opening files while a modifier key is pressed.
Notable Changes
- Added
.has-active-menuclass to file explorer item that received the right-click - Added
.list-bulletclass to HTML markup for unordered list items
Resources
GitHub Repository
View the full API source code and type definitions
Forum
Discuss API changes and request new features