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

Support Cloudflare #33

Open
bogeychan opened this issue May 22, 2024 · 0 comments · May be fixed by #34
Open

Support Cloudflare #33

bogeychan opened this issue May 22, 2024 · 0 comments · May be fixed by #34

Comments

@bogeychan
Copy link
Collaborator

bogeychan commented May 22, 2024

The following code doesn't work on Cloudflare because dynamic is false

const jwtType = t.Object({
  id: t.Number(),
});

export const authPlugin = new Elysia({ name: "authPlugin" }).use(
  jwt({
    secret: "yay",
    name: "jwt",
    exp: "20m",
    schema: jwtType,
  })
);

This function call missing dynamic parameter:

? getSchemaValidator(

Cloudflare error:

EvalError: Code generation from strings disallowed for this context

reported on discord

@bogeychan bogeychan linked a pull request May 22, 2024 that will close this issue
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

Successfully merging a pull request may close this issue.

1 participant