feat: add llms.txt endpoint for LLM-optimized documentation
Add /llms.txt endpoint that serves a concatenated, text-only version of all Tailwind CSS documentation pages optimized for Large Language Model consumption.
- Extract text from MDX files, removing JSX components and preserving code blocks
- Remove standalone HTML blocks (not in code blocks)
- Extract meaningful content from custom components (ApiTable, ResponsiveDesign, etc.)
- Statically generate the output at build time
- Include all 185 documentation files in proper order with sections
:)
@quantizor is attempting to deploy a commit to the Tailwind Labs Team on Vercel.
A member of the Team first needs to authorize it.
@petersuhm 👋
As a future enhancement, I'd like to introduce the markdown-to-jsx AST parser https://github.com/quantizor/markdown-to-jsx/pull/725 when it's ready so we can get rid of the gnarly regexes.
Now that v9 is out, I'll refactor this PR tonight.
@reinink this is ready to be reviewed