fix(storybook): if there is no propstype name do not add angle brackets
This commit is contained in:
parent
7b1860878f
commit
ce9dbd011c
@ -156,7 +156,7 @@ describe('react:component-story', () => {
|
|||||||
title: 'Test',
|
title: 'Test',
|
||||||
} as Meta;
|
} as Meta;
|
||||||
|
|
||||||
const Template: Story<> = (args) => <Test {...args} />;
|
const Template: Story = (args) => <Test {...args} />;
|
||||||
|
|
||||||
export const Primary = Template.bind({});
|
export const Primary = Template.bind({});
|
||||||
Primary.args = {};
|
Primary.args = {};
|
||||||
|
|||||||
@ -10,7 +10,7 @@ export default {
|
|||||||
<% } %>
|
<% } %>
|
||||||
}<% if ( !isPlainJs ) { %> as Meta <% } %>;
|
}<% if ( !isPlainJs ) { %> as Meta <% } %>;
|
||||||
|
|
||||||
const Template<% if ( !isPlainJs ) { %>: Story<<%= propsTypeName %>><% } %> = (args) => <<%= componentName %> {...args} />;
|
const Template<% if ( !isPlainJs ) { %>: Story<% if ( propsTypeName ) { %><<%= propsTypeName %>><% } %><% } %> = (args) => <<%= componentName %> {...args} />;
|
||||||
|
|
||||||
export const Primary = Template.bind({})
|
export const Primary = Template.bind({})
|
||||||
Primary.args = {<% for (let prop of props) { %>
|
Primary.args = {<% for (let prop of props) { %>
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user