chore: release main#9
Closed
pleaseai-bot[bot] wants to merge 1 commit into
Closed
Conversation
amondnet
added a commit
that referenced
this pull request
May 28, 2026
* feat(layer): add Vercel markdown-rewrite module
Adds a Nuxt module that injects Vercel build-output rewrite rules so
that AI agents (anything sending `Accept: text/markdown` or
`User-Agent: curl/*`) get served raw markdown instead of the SPA shell.
Behaviour:
- No-op on every non-Vercel preset (matches `vercel`, `vercel-edge`,
`vercel-static`, etc. via `preset.startsWith('vercel')`).
- On Vercel: read `<output.publicDir>/../config.json`, validate that
`llms.txt` was emitted, and unshift route pairs onto `routes` so
they fire before the SPA fallback.
- Rules:
- `/` -> `/llms.txt`
- `/<locale>` -> `/llms.txt` (per `runtimeConfig.public.i18n.locales`)
- `/<page>` -> `/raw<page>.md` for every `/raw/...md` link found
in `llms.txt`
- Vercel's `has` array is AND-ed, so OR semantics between the
`Accept` and `User-Agent` matchers require emitting two rules per
`src` -> `dest` pair.
- Locale codes are regex-escaped before being joined into the
alternation so exotic codes can't break the pattern.
Ports upstream docus commits `6fd8686b` and `9ceafe6f` -- see
`docs/docus-upstream-changes.md` item #9.
Verification:
- `bun lint` -> clean
- `bun typecheck` -> no new errors in `markdown-rewrite.ts`
- `NITRO_PRESET=vercel bun --filter @pleaseai/docs-site build`
injects two routes (homepage / Accept + User-Agent) into
`.vercel/output/config.json`.
- Default (cloudflare) build is unchanged; module bails silently.
* fix(layer): apply review suggestions
Apply review feedback from cubic-dev-ai and gemini-code-assist on
the markdown-rewrite module:
- Read locale config from `nuxt.options.i18n` instead of
`runtimeConfig.public.i18n` (matching the pattern used by the
`nitro:config` hook in nuxt.config.ts). The i18n module does
not always populate `runtimeConfig.public.i18n`, so the previous
source could silently miss locale routes. (cubic)
- Decode the URL pathname with `decodeURIComponent` so that paths
with URL-encoded characters (e.g. `%20`) match Vercel's router,
which compares against decoded request pathnames. (gemini)
- Allow an optional trailing slash on docs page route patterns
(`/?$` instead of `$`) so requests like
`/en/getting-started/installation/` are matched consistently
with the per-locale homepage routes. (cubic, gemini)
* Merge branch 'main' into worktree-agent-a1a3a89e87faf9e6d
Resolve modules-array conflict in packages/layer/nuxt.config.ts by
keeping both new module registrations from #29/#30/#31 and this PR's
markdown-rewrite module.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
🤖 I have created a release beep boop
docs: 1.0.0
1.0.0 (2025-12-04)
⚠ BREAKING CHANGES
Features
Bug Fixes
Documentation
Dependencies
docs-please: 0.2.0-beta.0
0.2.0-beta.0 (2025-12-04)
⚠ BREAKING CHANGES
Features
Bug Fixes
This PR was generated with Release Please. See documentation.