logseq-plugin-dev

Comprehensive guide and resources for developing Logseq plugins. Use this skill when asked to: (1) Create a new Logseq plugin, (2) Implement features using the Logseq Plugin API (Editor, App, DB, UI), (3) Debug or refactor existing Logseq plugins, (4) Set up a development environment for Logseq plugins.

Safety Notice

This listing is imported from skills.sh public index metadata. Review upstream SKILL.md and repository scripts before running.

Copy this and send it to your AI assistant to learn

Install skill "logseq-plugin-dev" with this command: npx skills add 0xrichardh/agent-skills/0xrichardh-agent-skills-logseq-plugin-dev

Logseq Plugin Development

This skill helps you build high-quality plugins for Logseq using the @logseq/libs SDK.

Core Concepts

Logseq plugins run in a sandboxed iframe and communicate with the main Logseq application via an RPC bridge.

  • Manifest: Every plugin needs a package.json with a logseq field.
  • SDK: Use @logseq/libs to interact with Logseq.
  • Lifecycle: Use logseq.ready(main) to initialize your plugin.

Getting Started

  1. Scaffold:
    • Basic TS: assets/template/
    • React + Vite: assets/template-react/
  2. Install Dependencies: npm install @logseq/libs.
  3. Build: Use Vite or a similar bundler to package your JS/TS code.
  4. Load: In Logseq, go to Settings -> Plugins -> Developer Mode, then Load unpacked plugin and select your plugin directory.

Common Workflows

1. Registering Commands

Use logseq.Editor.registerSlashCommand or logseq.App.registerCommandPalette.

2. Interacting with Content

  • Read: logseq.Editor.getCurrentPageBlocksTree()
  • Write: logseq.Editor.insertBlock(parentBlockId, content)
  • Query: logseq.DB.datascriptQuery(query)

3. UI and Theming

  • UI: Use logseq.provideUI to inject HTML or logseq.showMainUI to show a full-screen app.
  • Theming: Use Logseq CSS variables (e.g., --ls-primary-background-color) for consistency.

Resources

Source Transparency

This detail page is rendered from real SKILL.md content. Trust labels are metadata-based hints, not a safety guarantee.

Related Skills

Related by shared tags or category signals.

Coding

opencode-conversation-recall

No summary provided by upstream source.

Repository SourceNeeds Review
Coding

Planning with files

Implements Manus-style file-based planning to organize and track progress on complex tasks. Creates task_plan.md, findings.md, and progress.md. Use when aske...

Registry SourceRecently Updated
8.4K22Profile unavailable
Coding

Nutrient Document Processing (Universal Agent Skill)

Universal (non-OpenClaw) Nutrient DWS document-processing skill for Agent Skills-compatible products. Best for Claude Code, Codex CLI, Gemini CLI, Cursor, Wi...

Registry SourceRecently Updated
2740Profile unavailable
Coding

vercel-react-best-practices

React and Next.js performance optimization guidelines from Vercel Engineering. This skill should be used when writing, reviewing, or refactoring React/Next.js code to ensure optimal performance patterns. Triggers on tasks involving React components, Next.js pages, data fetching, bundle optimization, or performance improvements.

Repository Source
214.9K23Kvercel