This repository was archived by the owner on Dec 20, 2024. It is now read-only.
Repository navigation
Dynamic rewrites via vercel.json #1054
|
I want to utilize the rewrite functionality to proxy an API endpoint but the endpoint has to be different for the environments. For now I've done with a middleware and an environment variable but would like to use the environment inside of the rewrite rules. |
Answered by
amyegan
Nov 15, 2022
Replies: 2 comments
|
It sounds like you're already using the solution I would recommend, @floriangosse! Middleware is letting you use environment variables for rewrites, while a |
0 replies
Answer selected by
amyegan
|
Thanks for your quick answer. Would have been nice to use the rewrite feature because it reduces the usage functions. Maybe it could be a useful solution for the future to support environment variables in some parts of the |
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
It sounds like you're already using the solution I would recommend, @floriangosse! Middleware is letting you use environment variables for rewrites, while a
vercel.jsonconfig is not able to access them.