streamich / react-use

React Hooks — 👍
http://streamich.github.io/react-use
The Unlicense
41.57k stars 3.14k forks source link

useCopyToClipboard: accept options object to pass to copy-to-clipboard #2533

Open pietrofxq opened 9 months ago

pietrofxq commented 9 months ago

Is your feature request related to a problem? Please describe. The function exported by copy-to-clipboard library takes a second options parameter, that allows to change the MIME type or add a custom message. Currently the useCopyToClipboard hooks does not forward this option object.

Describe the solution you'd like The hook should accept and pass the options object to the copy-to-clipboard function call.

thetejasmagade commented 8 months ago

Hey @pietrofxq 👋, can you explain in brief or share some related links? I'm not able to understand it.

geanify commented 7 months ago

https://github.com/streamich/react-use/pull/2542