Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Is there an option to hide function implementation from props? #138

Open
yannbf opened this issue Mar 11, 2021 · 0 comments
Open

Is there an option to hide function implementation from props? #138

yannbf opened this issue Mar 11, 2021 · 0 comments
Labels

Comments

@yannbf
Copy link
Member

yannbf commented Mar 11, 2021

Describe the bug

Using Storybook 6 with args and auto added actions, this is an example of my component:

const Template = args => <AlertDialog {...args} />;

export const WithTwoButtons = Template.bind({});
WithTwoButtons.args = {
  open: true,
  description: 'Description',
  confirmLabel: 'Confirm',
  dismissLabel: 'Cancel',
};

onConfirm and onDismiss are not passed on purpose, so that actions can kick in automatically. However, this is the result in the addon:
image

Is there a way to configure the story (or globally) so that functions are redacted somehow?

This is how it looks like in the source from addon-docs tab:
image

@yannbf yannbf added the bug label Mar 11, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant