Open yikkwongwong opened 1 month ago
1.0.21
Darwin 23.4.0 arm64 arm
const app = new Elysia({ aot: false }).use(cors({ credentials: true, })).get("/", () => "Hello Elysia").listen(3000);
and do a curl localhost:3000 -X OPTIONS -v
curl localhost:3000 -X OPTIONS -v
Access-Control-Allow-Credentials header is not set in header. Upon digging @elysiajs/cors, app.headers(defaultHeaders) calls are not setting the headers when not in AOT mode.
CORS to be working properly with/ without AOT.
CORS only work properly with AOT.
No response
What version of Elysia.JS is running?
1.0.21
What platform is your computer?
Darwin 23.4.0 arm64 arm
What steps can reproduce the bug?
and do a
curl localhost:3000 -X OPTIONS -v
Access-Control-Allow-Credentials header is not set in header. Upon digging @elysiajs/cors, app.headers(defaultHeaders) calls are not setting the headers when not in AOT mode.
What is the expected behavior?
CORS to be working properly with/ without AOT.
What do you see instead?
CORS only work properly with AOT.
Additional information
No response