mirror of
https://github.com/logto-io/logto.git
synced 2024-12-23 20:33:16 -05:00
9 lines
355 B
TypeScript
9 lines
355 B
TypeScript
import { Hooks } from '@logto/schemas/models';
|
|
import { createModelRouter } from '@withtyped/postgres';
|
|
import type { QueryClient } from '@withtyped/server';
|
|
|
|
export type ModelRouters = ReturnType<typeof createModelRouters>;
|
|
|
|
export const createModelRouters = (queryClient: QueryClient) => ({
|
|
hook: createModelRouter(Hooks, queryClient).withCrud(),
|
|
});
|