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

Props redirect issue #49

Open
frandiox opened this issue Jul 28, 2021 · 0 comments
Open

Props redirect issue #49

frandiox opened this issue Jul 28, 2021 · 0 comments

Comments

@frandiox
Copy link
Owner

From Discord via @subhendukundu:

Lets say I have these routes.

functions/props/docs/[slug].js
and
functions/props/docs.js

and in /docs.js

export default {
    handler({ params = {}, query = {} }) {
        return {
            status: 302, // Any 3xx is accepted for a redirect
            headers: {
                location: "/docs/getting-started",
            },
        };
    },
    options: {
        cache: {
            api: 90,
            html: 90,
        },
    },
};

And this is affecting in docs/[slug] paths as well.

yes. I have two routes.

  1. /docs
  2. docs/[slug]
    And I am trying to redirect user from /docs to /docs/getting-started

git clone -b props-route https://github.com/subhendukundu/vitedge-react-template.git

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

No branches or pull requests

1 participant