Closed IVLIU closed 6 months ago
Thanks @IVLIU for the PR!
However, there have been several attempts to enhance types of APIs like useModal, modal.show, etc, but all failed and rolled back.
So I need to carefully look into code. You can also revisit the code again to make sure it covers all possibilities and is backward compatible with the current type definition.
I added a generic parameter to useModal and NiceModalHandler, which will affect the type of resolve and the return value type of show.