@doocs/md-cli 2.1.1 → 2.1.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/index.js CHANGED
@@ -29,7 +29,7 @@ async function startServer() {
29
29
 
30
30
  app.listen(port, '127.0.0.1', () => {
31
31
  console.log(`服务已启动:`)
32
- console.log(`打开链接 ${colors.green(`http://127.0.0.1:${port}/md/`)} 即刻使用吧~`)
32
+ console.log(`打开链接 ${colors.green(`http://127.0.0.1:${port}`)} 即刻使用吧~`)
33
33
  console.log(``)
34
34
 
35
35
  const { spaceId, clientSecret } = arg
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@doocs/md-cli",
3
- "version": "2.1.1",
3
+ "version": "2.1.2",
4
4
  "type": "module",
5
5
  "description": "WeChat Markdown Editor | 一款高度简洁的微信 Markdown 编辑器:支持 Markdown 语法、自定义主题样式、内容管理、多图床、AI 助手等特性",
6
6
  "main": "index.js",
package/server.js CHANGED
@@ -88,17 +88,10 @@ export function createServer(port = 8800) {
88
88
  }
89
89
  })
90
90
 
91
- app.get('/', (_, res) => {
92
- res.redirect('/md/')
93
- })
94
-
95
91
  console.log('代理到: https://md.doocs.org/')
96
- app.use('/md/', createProxyMiddleware({
92
+ app.use(createProxyMiddleware({
97
93
  target: 'https://md.doocs.org/',
98
94
  changeOrigin: true,
99
- pathRewrite: {
100
- '^/md/': '',
101
- },
102
95
  on: {
103
96
  error: (err, req, res) => {
104
97
  console.error(`代理错误 ${req.path}:`, err)