From 4a5a9418d4d3394863adbe632d658e9b015631e0 Mon Sep 17 00:00:00 2001 From: Kasper Peulen Date: Thu, 11 Apr 2024 13:25:41 +0200 Subject: [PATCH] Export CleanupCallback type --- src/story.ts | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/story.ts b/src/story.ts index e618bfe..222b3be 100644 --- a/src/story.ts +++ b/src/story.ts @@ -248,11 +248,12 @@ export type LoaderFunction context: StoryContextForLoaders ) => Promise | void> | Record | void; -export type Awaitable = T | PromiseLike; +type Awaitable = T | PromiseLike; +export type CleanupCallback = (() => Awaitable) | void; export type BeforeEach = ( context: StoryContextForLoaders -) => Awaitable<(() => Awaitable) | void>; +) => Awaitable; export interface StoryContext extends StoryContextForLoaders {