You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When trying to create a schema on v0.dev through secretvaults lib, this occurs:
The API returns HTTP 201 created as it always does for created schemas but the response does not allow this origin via CORS. Using nilDB has worked before on a regular Vercel deploy as well as from localhost.
The createSchema call is actually inside a server action which is inside a "use server" file and so should not have to do with CORS. But it seems v0 runs the backend code of the Next.js app in the browser which leads to this.
A reproducible example is here (upload repo contents to v0 as .zip to create a new chat from it).
The solution would be to allow the v0 origins (presumably *.lite.vusercontent.net) explicitly via CORS.
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
-
When trying to create a schema on v0.dev through
secretvaults
lib, this occurs:The API returns HTTP 201 created as it always does for created schemas but the response does not allow this origin via CORS. Using nilDB has worked before on a regular Vercel deploy as well as from localhost.
The
createSchema
call is actually inside a server action which is inside a"use server"
file and so should not have to do with CORS. But it seems v0 runs the backend code of the Next.js app in the browser which leads to this.A reproducible example is here (upload repo contents to v0 as .zip to create a new chat from it).
The solution would be to allow the v0 origins (presumably
*.lite.vusercontent.net
) explicitly via CORS.Beta Was this translation helpful? Give feedback.
All reactions