Skip to content

Commit

Permalink
fix: broaden component type definition
Browse files Browse the repository at this point in the history
  • Loading branch information
atanasster committed Mar 8, 2021
1 parent 1763074 commit 96113f2
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions core/core/src/common.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { ComponentType } from 'react';
import { ElementType } from 'react';
import { StoryRenderFn } from './utility';
import { ComponentControls } from './controls';

Expand Down Expand Up @@ -26,14 +26,14 @@ export interface StoryProps<Props = unknown> {
/**
* id for component associated with the story
*/
component?: string | Record<string, unknown> | ComponentType<Props>;
component?: string | Record<string, unknown> | ElementType<Props>;

/**
* multiple components option
*/
subcomponents?: Record<
string,
string | Record<string, unknown> | ComponentType<Props>
string | Record<string, unknown> | ElementType<Props>
>;

/**
Expand Down

0 comments on commit 96113f2

Please sign in to comment.