Skip to content

fix: redirect legacy public template entry to gallery - #3653

Draft
littleben wants to merge 1 commit into
teableio:developfrom
littleben:codex/redirect-legacy-template
Draft

littleben wants to merge 1 commit into
teableio:developfrom
littleben:codex/redirect-legacy-template

Conversation

@littleben

Copy link
Copy Markdown

Summary

Requests to https://app.teable.ai/public/template currently lead to a missing page. Add a host-scoped Next.js redirect to send that legacy entry point to https://teable.ai/templates with HTTP 301, preserving query parameters.

Use statusCode: 301 explicitly because permanent: true returns 308. The host matcher escapes the dots and the source matches only the entry path, leaving China-cloud and self-hosted domains, template-detail paths, and unrelated routes unaffected.

Validation

  • Loaded the edited application config and exercised it with Next.js 16.1.6's unstable_getResponseFromNextConfig on Node.js 22.
  • All 10 cases passed: HTTP/HTTPS entry requests, query-string preservation, China-cloud and self-hosted domains, a lookalike hostname, the marketing domain, template-detail paths, a similar path, and login.
  • Nonmatching cases were verified to produce no redirect; these config-level checks do not assert the final page status.
  • JavaScript syntax, Prettier 3.2.5 with repository formatting options, and git diff --check passed.
  • Full monorepo build and test suites were not run for this config-only change.

The redirect becomes live after the application deployment includes this change.

@CLAassistant

Copy link
Copy Markdown

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.
You have signed the CLA already but the status is still pending? Let us recheck it.

@littleben
littleben marked this pull request as draft September 19, 2026 08:17

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants