Fix type signature for .add()

This commit is contained in:
Tom Coleman 2020-02-18 16:33:46 +11:00
parent 060f0d6263
commit be5ef39135

View File

@ -129,7 +129,11 @@ export default class ClientApi {
};
});
api.add = (storyName: string, storyFn: string, parameters: Parameters = {}) => {
api.add = (
storyName: string,
storyFn: StoryFn<StoryFnReturnType>,
parameters: Parameters = {}
) => {
hasAdded = true;
const id = parameters.__id || toId(kind, storyName);