eBay / nice-modal-react

A modal state manager for React.
https://ebay.github.io/nice-modal-react
MIT License
1.96k stars 110 forks source link

chore: refine ts type #20

Closed xxleyi closed 2 years ago

xxleyi commented 2 years ago

Adjust some TS type definitions to provide better experience, when using React components with useModal, show and register function.

xxleyi commented 2 years ago

Please hide whitespace when review the code. I don't know why I add many whitespace when copy&paste into Github online code editor.


Already remove white space.

codecov-commenter commented 2 years ago

Codecov Report

Merging #20 (fa2595a) into main (7df29c8) will not change coverage. The diff coverage is 100.00%.

:exclamation: Current head fa2595a differs from pull request most recent head 6af399d. Consider uploading reports for the commit 6af399d to get more accurate results Impacted file tree graph

@@            Coverage Diff            @@
##              main       #20   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files            1         1           
  Lines          185       183    -2     
  Branches        29        29           
=========================================
- Hits           185       183    -2     
Impacted Files Coverage Δ
src/index.tsx 100.00% <100.00%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more Δ = absolute <relative> (impact), ø = not affected, ? = missing data Powered by Codecov. Last update 7df29c8...6af399d. Read the comment docs.

supnate commented 2 years ago

LGTM. Thanks @xxleyi for this fantastic enhancement 💪 Great job!

supnate commented 2 years ago

Published the change to v1.2.0.