Skip to content

Commit 1e9637c

Browse files
AyoubElkairhorns
authored andcommitted
update types
1 parent 8b99fb3 commit 1e9637c

File tree

1 file changed

+3
-2
lines changed
  • packages/fastify-renderer/src/node

1 file changed

+3
-2
lines changed

packages/fastify-renderer/src/node/types.ts

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ import {
1313
import { IncomingMessage, Server, ServerResponse } from 'http'
1414
import { ReactElement } from 'react'
1515
import { ViteDevServer } from 'vite'
16+
import { RegisteredRenderable } from './Plugin'
1617

1718
export type ServerRenderer<Props> = (
1819
this: FastifyInstance<Server, IncomingMessage, ServerResponse>,
@@ -48,7 +49,7 @@ export interface ServerEntrypointManifest {
4849
declare module 'fastify' {
4950
// // eslint-disable-next-line @typescript-eslint/no-unused-vars
5051
interface FastifyInstance {
51-
registerRenderable: (renderable: string) => void
52+
registerRenderable: (renderable: string) => RegisteredRenderable
5253
}
5354

5455
interface RouteShorthandOptions<RawServer extends RawServerBase = RawServerDefault> {
@@ -59,7 +60,7 @@ declare module 'fastify' {
5960
vite: ViteDevServer
6061
}
6162
interface FastifyReply {
62-
render: <Props>(this: FastifyReply, renderable: string, props: Props) => Promise<void>
63+
render: <Props>(this: FastifyReply, renderable: RegisteredRenderable, props: Props) => Promise<void>
6364
}
6465

6566
interface RouteShorthandMethod<

0 commit comments

Comments
 (0)