Skip to content

Commit

Permalink
Add async render types
Browse files Browse the repository at this point in the history
  • Loading branch information
mattcompiles committed Aug 13, 2020
1 parent b87bb37 commit 93e8e34
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 3 deletions.
5 changes: 5 additions & 0 deletions .changeset/strong-rules-pretend.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'sku': patch
---

Add async render types
6 changes: 3 additions & 3 deletions sku-types.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,13 +18,13 @@ interface RenderDocumentProps<App> extends RenderAppProps {
}

export interface Render<App = string> {
renderApp(p: RenderAppProps): App;
renderApp(p: RenderAppProps): Promise<App> | App;

provideClientContext?(p: {
environment: string;
site: string;
app: App;
}): object;
}): Promise<object> | object;

renderDocument(p: RenderDocumentProps<App>): string;
renderDocument(p: RenderDocumentProps<App>): Promise<string> | string;
}

0 comments on commit 93e8e34

Please sign in to comment.