Skip to content

Commit

Permalink
Render functions as their name
Browse files Browse the repository at this point in the history
This will replace `function noRefCheck () {}` with `function ${name}` when
checking the code of a story
  • Loading branch information
d-claassen committed Mar 1, 2024
1 parent f186110 commit 13c6ad9
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions packages/ui-library/.storybook/preview.js
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,9 @@ export const globalTypes = {

export const parameters = {
viewMode: "docs",
jsx: {
functionValue: (fn) => fn.name ? `function ${fn.name}` : fn,
},
options: {
storySort: {
order: [
Expand Down

0 comments on commit 13c6ad9

Please sign in to comment.