Skip to content

Commit

Permalink
Allow getMarkupFromTree options.renderFunction to return PromiseLike<…
Browse files Browse the repository at this point in the history
…string>.
  • Loading branch information
benjamn committed Jul 21, 2020
1 parent 8c9cfc5 commit 950dce2
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/react/ssr/getDataFromTree.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,9 @@ export function getDataFromTree(
export type GetMarkupFromTreeOptions = {
tree: React.ReactNode;
context?: { [key: string]: any };
renderFunction?: (tree: React.ReactElement<any>) => string | Promise<string>;
renderFunction?: (
tree: React.ReactElement<any>,
) => string | PromiseLike<string>;
};

export function getMarkupFromTree({
Expand Down

0 comments on commit 950dce2

Please sign in to comment.