Skip to content

Commit 779f157

Browse files
docs: remove unused _redirects file and document redirect process (#21144)
The _redirects file format is used by Netlify and Cloudflare Pages, but coder.com runs on Vercel with Next.js. Redirects for coder.com/docs must be configured in the coder/coder.com repository redirects.json file. This file was never functional and caused confusion when renaming docs. Co-authored-by: blink-so[bot] <211532188+blink-so[bot]@users.noreply.github.com>
1 parent ea9f003 commit 779f157

File tree

2 files changed

+12
-13
lines changed

2 files changed

+12
-13
lines changed

.claude/docs/DOCS_STYLE_GUIDE.md

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -300,10 +300,22 @@ Some content is auto-generated with comments:
300300

301301
Don't manually edit auto-generated sections.
302302

303+
## URL Redirects
304+
305+
When renaming or moving documentation pages, redirects must be added to prevent broken links.
306+
307+
**Important**: Redirects are NOT configured in this repository. The coder.com website runs on Vercel with Next.js and reads redirects from a separate repository:
308+
309+
- **Redirect configuration**: https://github.com/coder/coder.com/blob/master/redirects.json
310+
- **Do NOT create** a `docs/_redirects` file - this format (used by Netlify/Cloudflare Pages) is not processed by coder.com
311+
312+
When you rename or move a doc page, create a PR in coder/coder.com to add the redirect.
313+
303314
## Key Principles
304315

305316
1. **Research first** - Verify against actual code implementation
306317
2. **Be precise** - Use exact numbers, permission names, API paths
307318
3. **Visual structure** - Organize around screenshots when available
308319
4. **Link everything** - Related docs, API endpoints, CLI references
309320
5. **Manifest inclusion** - Add to manifest.json for navigation
321+
6. **Add redirects** - When moving/renaming pages, add redirects in coder/coder.com repo

docs/_redirects

Lines changed: 0 additions & 13 deletions
This file was deleted.

0 commit comments

Comments
 (0)