Skip to content

Instantly share code, notes, and snippets.

@tomfa
Created January 5, 2022 19:29
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save tomfa/f204d5518ac8a2c8730da83f4e6e369c to your computer and use it in GitHub Desktop.
Save tomfa/f204d5518ac8a2c8730da83f4e6e369c to your computer and use it in GitHub Desktop.
Example storybook
import React from 'react';
import { Meta } from '@storybook/react';
import Component from './ImageIcon';
export default {
title: 'components/ImageIcon/ImageIcon',
component: Component,
} as Meta;
const Template = (props: React.ComponentProps<typeof Component>) => <Component {...props} />;
export const ImageIcon = Template.bind({});
ImageIcon.args = {
src: 'https://i.pinimg.com/564x/ea/b8/60/eab860a9c45b720fbc527bd304e12a68.jpg',
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment