Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Redirect dust.tt/jobs to ashby #9326

Merged
merged 2 commits into from
Dec 12, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion front/components/home/menu/config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ const CareersMenuConfig: MenuConfig = {
},
{
title: "Jobs",
href: "https://jobs.ashbyhq.com/dust",
href: "/jobs",
isExternal: true,
},
],
Expand Down
10 changes: 10 additions & 0 deletions front/pages/jobs.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
export async function getServerSideProps() {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let's move this redirect to next.config.js instead

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

About benefits:

  • Performance: Redirects are handled at the edge/server level
  • SEO-friendly: Proper HTTP status codes
  • Flexibility: Supports patterns and dynamic parameters
  • Maintenance: All redirects in one place
  • Build-time validation: Next.js validates the configuration

return {
redirect: {
destination: "https://jobs.ashbyhq.com/dust",
permanent: true,
},
};
}

export default function Jobs() {}
Loading