logseq/libs
Charlie dda1f9bd9f
Enhance / Plugin APIs (#6945)
Added
1. All configurations of current graph.
App.getCurrentGraphConfigs: () => Promise<any>
2. All favorite pages list of current graph.
App.getCurrentGraphFavorites: () => Promise<Array<string> | null>
3. All recent pages list of current graph.
App.getCurrentGraphRecent: () => Promise<Array<string> | null>
4. Clear right sidebar blocks.
App.clearRightSidebarBlocks: (opts?: { close: boolean }) => void
5. Support register CodeMirror enhancer. #Experiment feature
Experiments.registerExtensionsEnhancer<T = any>(type: 'katex' | 'codemirror', enhancer: (v: T) => Promise<any>)
6. Support hooks for app search service. #Alpha stage
App.registerSearchService<T extends IPluginSearchServiceHooks>(s: T): void
7. Support focus option for App.insertBlock. Credit to [[tennox]] #PR

Fixed
1. Adjust build script to be compatible for shadow-cljs bundler.
How to set up a clojurescript project with shadow-cljs?
https://github.com/rlhk/logseq-url-plus/blob/main/doc/dev-notes.md
2022-11-22 22:00:29 +08:00
..
src Enhance / Plugin APIs (#6945) 2022-11-22 22:00:29 +08:00
.gitignore feat!: File Sync (#5355) 2022-09-01 00:31:49 +08:00
.npmignore Enhance / Plugin APIs (#6945) 2022-11-22 22:00:29 +08:00
.prettierrc.js Enhance/more ns plugin api (#4828) 2022-04-21 18:43:16 +08:00
CHANGELOG.md Enhance / Plugin APIs (#6945) 2022-11-22 22:00:29 +08:00
README.md chore(plugin): build libs core & update README.md 2022-04-29 18:51:25 +08:00
babel.config.json Enhance / Plugin APIs (#6945) 2022-11-22 22:00:29 +08:00
index.d.ts feat(plugin): merge implementation 2021-05-08 20:32:20 +08:00
package.json Enhance / Plugin APIs (#6945) 2022-11-22 22:00:29 +08:00
tsconfig.json improve(plugin): simplify caller 2021-08-23 18:19:06 +08:00
webpack.config.core.js Enhance/plugin apis (#3355) 2021-12-08 10:43:58 +08:00
webpack.config.js Enhance / Plugin APIs (#6945) 2022-11-22 22:00:29 +08:00
yarn.lock Enhance / Plugin APIs (#6945) 2022-11-22 22:00:29 +08:00

README.md

@logseq/libs

🚀 Logseq SDK libraries.

Installation

yarn add @logseq/libs

Usage

Load logseq plugin sdk as global namespace

import "@logseq/libs"

APIs & Samples

Community templates

  1. https://github.com/pengx17/logseq-plugin-template-react
  2. https://github.com/pengx17/logseq-plugin-template-svelte
  3. https://github.com/tiensonqin/logseq-cljs-playground

Feedback

If you have any feedback or encounter any issues, feel free to join Logseq's discord group. https://discord.gg/KpN4eHY