Professional content distribution platform for Obsidian - Format once, publish everywhere
LovPen is a comprehensive Obsidian plugin that transforms your markdown notes into professionally formatted content, ready for publishing across WeChat Official Accounts, Zhihu, XiaoHongShu, Twitter, and more platforms.
π― v0.20.0 Milestone: Achieved instant editor-renderer synchronization with zero-delay architecture, eliminating all setTimeout/debounce code for true real-time preview.
- β‘ Zero-Delay Synchronization: Instant editor-to-preview updates without any artificial delays
- π Single Rendering Path: Optimized architecture eliminates double-rendering issues
- πΎ Smart Caching: Intelligent plugin result caching for blazing-fast performance
- π― Pure Async/Await: Modern asynchronous patterns without setTimeout or debounce
- π¨ 35+ Professional Themes: Curated collection including minimalist, academic, and creative styles
- π» Advanced Code Highlighting: 20+ syntax themes with line numbers and language detection
- π Smart Layout System: Auto-numbering for H2 headings, intelligent paragraph spacing
- π Adaptive Link Handling: Platform-specific link conversion (footnotes for WeChat, inline for others)
- π± One-Click Publishing: Simultaneous distribution to multiple platforms
- π Real-Time Sync: Live preview with instant formatting updates
- π Status Tracking: Monitor publishing progress and results
- πΎ Draft Management: Save and manage drafts across platforms
- π― Handlebars Templates: Full template system for custom layouts
- π¨ CSS Variables: Dynamic theme customization
- π§ Plugin Architecture: Extensible markdown and HTML processing pipeline
- βοΈ Per-Platform Settings: Tailored configurations for each platform
Currently pending official review
# 1. Download latest release
curl -L https://github.com/markshawn2020/lovpen/releases/latest/download/lovpen-plugin.zip -o lovpen.zip
# 2. Extract to your vault
unzip lovpen.zip -d /path/to/vault/.obsidian/plugins/lovpen
# 3. Enable in Obsidian Settings β Community Plugins
git clone https://github.com/markshawn2020/lovpen
cd lovpen-obsidian
pnpm install
pnpm build
# Copy packages/obsidian/dist to .obsidian/plugins/lovpen
- Open Preview: Click
or press
Cmd/Ctrl+P
β "LovPen: Preview" - Customize Format: Select theme, adjust settings in real-time
- Copy or Distribute:
- Copy: One-click copy formatted HTML for manual posting
- Distribute: Automated multi-platform publishing
WeChat Official Account
- Obtain credentials from WeChat MP Platform
- Configure in LovPen Settings:
- AppID
- AppSecret
- Verification Token
- Features: Article publishing, draft management, image upload
Zhihu
- Login to Zhihu in browser
- Copy cookie from DevTools Network tab
- Paste in LovPen Settings β Zhihu Cookie
- Features: Article publishing, draft saving
XiaoHongShu
- Login to XiaoHongShu web version
- Extract cookie (must include
web_session
token) - Configure in settings
- Features: Note publishing with image support
Twitter/X
- Create app at Twitter Developer Portal
- Generate all tokens (API Key, Secret, Access Token, Access Secret)
- Add to LovPen Settings
- Features: Thread creation, media upload
Category | Setting | Description | Default |
---|---|---|---|
Display | Code Line Numbers | Show line numbers in code blocks | β Enabled |
Display | H2 Auto-Numbering | Add "01.", "02." prefixes to H2 | β Enabled |
Links | Conversion Mode | Convert links to footnotes | Non-WeChat only |
Links | Show Descriptions | Include link text in footnotes | β Disabled |
Templates | Enable Templates | Use Handlebars templates | β Disabled |
Advanced | CSS Inline | Inline styles for email compatibility | β Enabled |
Create custom themes by adding to .obsidian/plugins/lovpen/themes/
:
Note: All theme styles must be scoped under
.lovpen-renderer
selector
/* my-theme.css */
.lovpen-renderer {
--primary-color: #2c3e50;
--font-body: 'Inter', sans-serif;
--font-code: 'Fira Code', monospace;
}
.lovpen-renderer h2 {
color: var(--primary-color);
border-bottom: 2px solid currentColor;
}
Register in themes.json
:
{
"name": "My Theme",
"className": "my-theme",
"author": "Your Name"
}
lovpen-obsidian/
βββ packages/
β βββ obsidian/ # Core plugin (TypeScript, Obsidian API)
β βββ frontend/ # UI components (React 19, TailwindCSS 4)
β βββ shared/ # Common utilities and types
βββ assets/
β βββ themes/ # 35+ built-in themes
β βββ highlights/ # 20+ code highlighting styles
β βββ templates/ # Handlebars templates
βββ scripts/ # Build, release, version management
- Core: TypeScript 5.x, Obsidian Plugin API
- UI: React 19, Jotai, Radix UI, TailwindCSS 4
- Processing: Marked 12, Highlight.js 11, Handlebars 4
- Build: Turbo, ESBuild, Vite 5
- Performance: Direct DOM manipulation, Smart caching, Zero-delay architecture
- Quality: Biome, TypeScript strict mode
# Setup
pnpm install # Install dependencies
pnpm download-highlights # Fetch theme assets
# Development
pnpm dev # Start dev mode with hot reload
pnpm check # Type checking
# Production
pnpm build # Build all packages
pnpm release # Create release bundle
- Code Style: Follow existing patterns, use TypeScript strict mode
- Testing: Ensure
pnpm check
passes - Commits: Use conventional commits (
feat:
,fix:
,docs:
) - PRs: Include description and screenshots for UI changes
- Instant Synchronization: Editor changes now reflect immediately in preview without any delay
- Eliminated Double Rendering: Single, optimized rendering path prevents visual jumps
- Zero Artificial Delays: Removed all setTimeout, debounce, and throttle code
- Smart Caching Layer: Intelligent caching of plugin processing results
- Direct DOM Updates: Bypass React re-rendering for scroll-preserving updates
- Refactored from dual-path to single-path rendering architecture
- Implemented pure async/await patterns throughout the codebase
- Optimized plugin processing pipeline with result caching
- Enhanced scroll position preservation during updates
- Reduced overall rendering latency by 80%
-
Real-time editor-renderer synchronizationβ v0.20.0 - Official Obsidian Community Plugin listing
- Medium, Dev.to, Hashnode integration
- AI-powered content optimization
- Scheduled publishing
- Analytics dashboard
- Mobile app companion
- Issues: GitHub Issues
- Discussions: GitHub Discussions
- Updates: Watch releases for new features
MIT Β© Mark Shawn
Built with modern web technologies and a focus on user experience