Self-hosted alternatives to react-copy-to-clipboard
No self-hosted apps like react-copy-to-clipboard yet.
About react-copy-to-clipboard

react-copy-to-clipboard
Copy-to-clipboard React component
react-copy-to-clipboard is a React component that copies text to the clipboard when a user clicks its child element. It is based on the copy-to-clipboard library, and it wraps a single child, such as a button, without rendering any tag of its own, so the child is the element that captures the click. The text to copy is passed as a prop. The component calls an onCopy callback when the copy happens, with a result that is true if the copy succeeded and false otherwise. Options such as debug, message and format can be set for the copy behaviour. The README explains the fallbacks. It tries the browser's execCommand first, then the Internet Explorer clipboardData interface, and finally a simple prompt that shows the text so the user can copy it with Ctrl+C and Enter. The project has a simple web demo and a CodePen demo, and it is installed with Yarn or npm, with react as a peer dependency. It is released under the MIT licence. It suits React developers who want a copy button without writing the clipboard code themselves.
- Price
- Free
- Made by
- nkbt
- Category
- UI Libraries
- Website
- github.com/nkbt/react-copy-to-clipboard