Quick update to allow query params from function#10
Open
tfluehr wants to merge 1 commit intostorybook-community:mainfrom
Open
Quick update to allow query params from function#10tfluehr wants to merge 1 commit intostorybook-community:mainfrom
tfluehr wants to merge 1 commit intostorybook-community:mainfrom
Conversation
Sidnioulz
reviewed
Aug 14, 2025
Member
Sidnioulz
left a comment
There was a problem hiding this comment.
Thanks for the PR @tfluehr!
Would you be kind enough to set up tests for this? Having multiple types on the same data structure is probably when this package starts needing unit tests to handle edge cases and wrong input types.
Also, we would need an update to the README with a documented example. It would be easier to understand that example if it only had the query function and not mapParams. Having mapParams made me question for a moment why I couldn't mock data in my render function, which diverted me from appreciating the actual benefit of the feature.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
I had a need for a callback to dynamically build the query params. Sharing the approach I put together.
Add an additional story to demonstrate it in action.
Feel free to change as needed if you find it useful