英文:
Nuxt 3, Vercel deploy only one edge function
问题
I have a Nuxt 3 app that I deployed on Vercel. I'm wondering if there's a way to deploy only one of my endpoints as an edge function, while the rest remain as serverless functions. I tried configuring it with runtime: "edge"
but it didn't work, as all of them still seem to be serverless functions.
If I set the nitro
preset, all of my functions become edge functions. However that's not what I want. I only need one endpoint to be an edge function.
Is that currently possible with Nuxt 3?
英文:
I have a Nuxt 3 app that I deployed on Vercel. I'm wondering if there's a way to deploy only one of my endpoints as an edge function, while the rest remain as serverless functions. I tried configuring it with 'runtime: "edge"'
export const config = {
runtime: "edge",
}
but it didn't work, as all of them still seem to be serverless functions.
If I set the 'nitro' preset, all of my functions become edge functions. However that's not what I want. I only need one endpoint to be an edge function.
Is that currently possible with nuxt 3?
答案1
得分: 0
Nitro目前还不支持这种行为,但在他们的路线图中有提到,详见:https://github.com/unjs/nitro/issues/1120
英文:
Nitro is not supporting this kind of behavior yet but it's in their roadmap, see: https://github.com/unjs/nitro/issues/1120
通过集体智慧和协作来改善编程学习和解决问题的方式。致力于成为全球开发者共同参与的知识库,让每个人都能够通过互相帮助和分享经验来进步。
评论