Skip to content
Discussion options

You must be logged in to vote

Hi @lecramr, apologies for the late response. Defining variants will indeed create overhead and often targeted for use cases where multiple variants reuse the same components, e.g. notification toast. For dialog / modal, I recommend sticking with custom push.

I just pushed a patch that should improve the type inference for custom push, available in async-stack@1.0.1. Please give it another go and let me know if that helps. FYI typescript may yield misleading error about the variant until you have passed in the necessary props for the custom-pushed component.

The inference wasn't working previously because dts-buddy didn't seem to be able to output the correct type for the overloaded metho…

Replies: 2 comments 3 replies

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
3 replies
@vnphanquang
Comment options

Answer selected by lecramr
@vnphanquang
Comment options

@lecramr
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants