-
Notifications
You must be signed in to change notification settings - Fork 0
Add a custom URL transform option #3
Copy link
Copy link
Open
Description
At the moment auto only supports lower kebab-case file structures and Github URLs are case sensitive.
I think that to offer max flexibility, we'd have a function parameter which receives the story like so:
parameters: {
transformUrl(story) {
return story.title;
}
}
An attempt at this was already made, but unfortunately, it seems like Storybook doesn't support function parameters – it never makes it through to the useParameter hook.
Another option I've considered is to have a format option, that could specify the casing "kebab-case, "camelCase", "PascalCase" etc. It's a bit less flexible but would be an easy way to cover more file structures.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels