返回顶部
m

markdown-editor-with-chat

Lightweight markdown editor with optional OpenClaw gateway chat. Filesystem-based, no database required.

作者: admin | 来源: ClawHub
源自
ClawHub
版本
V 1.1.2
安全检测
已通过
737
下载量
0
收藏
概述
安装方式
版本历史

markdown-editor-with-chat

# Markdown Editor with Chat A lightweight, self-contained markdown editor that serves files from a local directory with optional OpenClaw gateway chat integration. ## Features - **Filesystem-based**: Point to any directory containing markdown files - **No database**: Files are the source of truth - **Folder navigation**: Browse nested directories - **Live preview**: See rendered markdown as you type - **Optional chat**: Connect to OpenClaw gateway for AI assistance - **Zero external dependencies**: Pure Node.js, self-contained HTML ## Quick Start ```bash # Start with CLI arguments (recommended) node scripts/server.mjs --folder /path/to/markdown --port 3333 # Or short form node scripts/server.mjs -f /path/to/markdown -p 3333 # With gateway chat enabled (via env vars) export OPENCLAW_GATEWAY_URL=http://127.0.0.1:18789 export OPENCLAW_GATEWAY_TOKEN=your-token node scripts/server.mjs -f /path/to/markdown ``` Then open http://localhost:3333 in your browser. ## CLI Arguments | Argument | Short | Required | Default | Description | |----------|-------|----------|---------|-------------| | `--folder` | `-f` | Yes* | - | Directory containing markdown files | | `--port` | `-p` | No | 3333 | Server port | | `--host` | `-h` | No | 127.0.0.1 | Server host (localhost only by default) | | `--help` | | No | | Show help message | *Required unless `MARKDOWN_DIR` env var is set. ## Environment Variables (fallback) | Variable | Required | Default | Description | |----------|----------|---------|-------------| | `MARKDOWN_DIR` | Yes* | - | Directory containing markdown files | | `PORT` | No | 3333 | Server port | | `HOST` | No | 127.0.0.1 | Server host | | `OPENCLAW_GATEWAY_URL` | No | - | Gateway URL for chat feature | | `OPENCLAW_GATEWAY_TOKEN` | No | - | Gateway auth token | CLI arguments take precedence over environment variables. ## Security - **Localhost only by default**: Server binds to 127.0.0.1, rejects public IPs - **Same-origin only**: No CORS headers, browser enforces same-origin policy - **Path traversal protection**: Cannot access files outside MARKDOWN_DIR - **No credentials in code**: All secrets via environment variables - **Gateway proxy**: Tokens never exposed to browser This is a local development tool. The API is intentionally simple (no auth) because it's designed for localhost use on directories you control. ## API Endpoints - `GET /` - Serves the editor UI - `GET /api/files` - List files and folders - `GET /api/files/:path` - Get file content - `PUT /api/files/:path` - Save file content - `POST /api/files/:path` - Create new file - `POST /api/chat` - Proxy chat to gateway (if configured) ## Use Cases - Browse and edit OpenClaw pearls - Personal markdown wiki - Note-taking with AI assistance - Documentation browser

标签

skill ai

通过对话安装

该技能支持在以下平台通过对话安装:

OpenClaw WorkBuddy QClaw Kimi Claude

方式一:安装 SkillHub 和技能

帮我安装 SkillHub 和 markdown-editor-with-chat-1776420072 技能

方式二:设置 SkillHub 为优先技能安装源

设置 SkillHub 为我的优先技能安装源,然后帮我安装 markdown-editor-with-chat-1776420072 技能

通过命令行安装

skillhub install markdown-editor-with-chat-1776420072

下载 Zip 包

⬇ 下载 markdown-editor-with-chat v1.1.2

文件大小: 13.51 KB | 发布时间: 2026-4-17 19:37

v1.1.2 最新 2026-4-17 19:37
Security: restrict file access to .md only, block dotfiles

Archiver·手机版·闲社网·闲社论坛·羊毛社区· 多链控股集团有限公司 · 苏ICP备2025199260号-1

Powered by Discuz! X5.0   © 2024-2025 闲社网·线报更新论坛·羊毛分享社区·http://xianshe.com

p2p_official_large
返回顶部