import { Story , Meta } from '@storybook/react' ; import { SubPage } from './SubPage' ; import React from 'react' ; interface IProps { title ? : string ; emptyTitle : string ; goBack : ( ) => void ; } const Template = ( args ) => ( < SubPage { ... args } > < div > Children Elements will go here < /div> < /SubPage>); export const SubPageView = Template . bind ( { } ) ; SubPageView . args = { title : 'Birth Registration' , emptyTitle : 'Empty Page' , goBack : ( ) => alert ( 'Back Button Clicked' ) } ; export default { title : 'Components/Interface/SubPage' , component : SubPage } as Meta ;