stack/docs/src/app
Madison d601e99c6c
init deeplink redirects (#804)
<!--

Make sure you've read the CONTRIBUTING.md guidelines:
https://github.com/stack-auth/stack-auth/blob/dev/CONTRIBUTING.md

-->


Fix for a lot of the deep links that are causing 404 errors from old
docs.

<!-- ELLIPSIS_HIDDEN -->


----

> [!IMPORTANT]
> Adds dynamic redirection for documentation routes in multiple
sections, redirecting to the correct page or an overview, with special
handling for REST API routes.
> 
>   - **Behavior**:
> - Adds dynamic redirection for documentation routes in `js`, `next`,
`python`, `react`, and `rest-api` sections.
> - Redirects to the correct documentation page or an overview if the
page doesn't exist.
>     - For `rest-api`, redirects to `/api` instead of `/docs`.
>   - **Files**:
> - `route.ts` in `js`, `next`, `python`, `react`, and `rest-api`
sections handle the redirection logic.
> - Uses `source.getPage()` or `apiSource.getPage()` to check page
existence.
> 
> <sup>This description was created by </sup>[<img alt="Ellipsis"
src="https://img.shields.io/badge/Ellipsis-blue?color=175173">](https://www.ellipsis.dev?ref=stack-auth%2Fstack-auth&utm_source=github&utm_medium=referral)<sup>
for 50c4b592a4. You can
[customize](https://app.ellipsis.dev/stack-auth/settings/summaries) this
summary. It will automatically update as commits are pushed.</sup>

----


<!-- ELLIPSIS_HIDDEN -->

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

* **New Features**
* Added dynamic redirection for documentation routes in JavaScript,
Next.js, Python, React, and REST API sections. Users are now
automatically redirected to the correct documentation page if it exists,
or receive a 404 not found response if the page is missing. This
improves navigation and error handling for documentation URLs.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->

---------

Co-authored-by: Konsti Wohlwend <n2d4xc@gmail.com>
2025-07-30 13:18:17 -05:00
..
(home) Adds oauth providers, fixes bottom page navigation with mobile suppor… (#726) 2025-07-08 19:51:24 -07:00
api Revert back to Gemini 2.0 Flash 2025-07-18 10:01:00 -07:00
docs Docs updates (#753) 2025-07-11 10:00:02 -07:00
js/[...path] init deeplink redirects (#804) 2025-07-30 13:18:17 -05:00
llms.mdx/[[...slug]] Adds oauth providers, fixes bottom page navigation with mobile suppor… (#726) 2025-07-08 19:51:24 -07:00
llms.txt Llms.txt (#724) 2025-06-27 13:28:55 -05:00
next/[...path] init deeplink redirects (#804) 2025-07-30 13:18:17 -05:00
openapi/[...path] New docs (#698) 2025-06-20 13:30:01 -07:00
python/[...path] init deeplink redirects (#804) 2025-07-30 13:18:17 -05:00
react/[...path] init deeplink redirects (#804) 2025-07-30 13:18:17 -05:00
rest-api/[...path] init deeplink redirects (#804) 2025-07-30 13:18:17 -05:00
favicon.ico Update favicons 2025-07-17 09:56:08 -07:00
global.css Docs updates (#753) 2025-07-11 10:00:02 -07:00
layout.config.tsx New docs (#698) 2025-06-20 13:30:01 -07:00
layout.tsx [Docs] posthog Integration (#761) 2025-07-14 13:49:36 -05:00