Open hckhanh opened 4 months ago
I leave the wrapper here for someone needs it
import type { RequestHandler } from '@builder.io/qwik-city'
import { serve } from 'inngest/cloudflare'
import {
createSkillIndex,
deleteSkillIndex,
createPostIndex,
deletePostIndex,
} from '~/inngest/functions'
import inngest from '~/inngest'
const inngestRequest = serve({
client: inngest,
streaming: 'allow',
signingKey: import.meta.env.VITE_INNGEST_SIGNING_KEY,
functions: [createPostIndex, deletePostIndex, createSkillIndex, deleteSkillIndex],
})
const onRequest: RequestHandler = async ({ send, request, platform }) => {
const response = await inngestRequest({
request,
env: platform.env as Record<string, undefined | string>,
})
send(response)
}
export const onGet = onRequest
export const onPost = onRequest
export const onPut = onRequest
Is your feature request related to a problem? Please describe.
I think that Qwik integration should be added