From 07f7c49ce55f1e45de09b875fdc6adebc4670f35 Mon Sep 17 00:00:00 2001 From: Thomas Thiebaud Date: Tue, 22 Sep 2020 19:50:17 +0200 Subject: [PATCH] feat: export RouteGeneric --- src/index.ts | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/src/index.ts b/src/index.ts index 6c5b75a..9d96c5c 100644 --- a/src/index.ts +++ b/src/index.ts @@ -86,15 +86,17 @@ ${await compile( )} ${await generateReplyInterfaces(options.prefix, schema.response)} -type ${options.prefix}Handler = RouteHandler<{ +type ${options.prefix}RouteGeneric = { Querystring: ${options.prefix}Query; Body: ${options.prefix}Body; Params: ${options.prefix}Params; Headers: ${options.prefix}Headers; Reply: ${options.prefix}Reply; -}>; +} + +type ${options.prefix}Handler = RouteHandler<${options.prefix}RouteGeneric>; -export { ${options.prefix}Handler, schema }\ +export { ${options.prefix}Handler, ${options.prefix}RouteGeneric, schema }\ `; }