@docsector/docsector-reader 1.2.0 → 1.2.1

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/bin/docsector.js CHANGED
@@ -23,7 +23,7 @@ const packageRoot = resolve(__dirname, '..')
23
23
  const args = process.argv.slice(2)
24
24
  const command = args[0]
25
25
 
26
- const VERSION = '1.2.0'
26
+ const VERSION = '1.2.1'
27
27
 
28
28
  const HELP = `
29
29
  Docsector Reader v${VERSION}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@docsector/docsector-reader",
3
- "version": "1.2.0",
3
+ "version": "1.2.1",
4
4
  "description": "A documentation rendering engine built with Vue 3, Quasar v2 and Vite. Transform Markdown into beautiful, navigable documentation sites.",
5
5
  "productName": "Docsector Reader",
6
6
  "author": "Rodrigo de Araujo Vieira",
@@ -1060,12 +1060,18 @@ export async function onRequest (context) {
1060
1060
  }
1061
1061
  }
1062
1062
 
1063
- if (config.mcp && !routes.include.includes('/mcp')) {
1063
+ if (markdownNegotiationEnabled && !routes.include.includes('/*')) {
1064
+ routes.include.push('/*')
1065
+ }
1066
+
1067
+ if (config.mcp && !markdownNegotiationEnabled && !routes.include.includes('/mcp')) {
1064
1068
  routes.include.push('/mcp')
1065
1069
  }
1066
1070
 
1067
- if (markdownNegotiationEnabled && !routes.include.includes('/*')) {
1068
- routes.include.push('/*')
1071
+ // Cloudflare Pages rejects overlapping include rules (e.g. "/mcp" with "/*").
1072
+ // Keep only the catch-all when markdown negotiation is enabled.
1073
+ if (routes.include.includes('/*')) {
1074
+ routes.include = routes.include.filter((route) => route !== '/mcp')
1069
1075
  }
1070
1076
 
1071
1077
  const markdownExcludes = [