npm.io
1.0.3 • Published 2 years ago

@types/simple-react-clipboard

Licence
MIT
Version
1.0.3
Deps
1
Size
4 kB
Vulns
0
Weekly
0
Stars
51.4K

Installation

npm install --save @types/simple-react-clipboard

Summary

This package contains type definitions for simple-react-clipboard (https://github.com/donfour/simple-react-clipboard#readme).

Details

Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/simple-react-clipboard.

index.d.ts

import { JSX, ReactNode } from "react";

interface ClipboardProps {
    render: (arg0: { copy: () => void }) => ReactNode;
    text: string;
    props?: object | undefined;
    // eslint-disable-next-line @typescript-eslint/no-invalid-void-type
    onSuccess?: () => void | undefined;
    // eslint-disable-next-line @typescript-eslint/no-invalid-void-type
    onError?: () => void | undefined;
}

declare function Clipboard({
    render,
    text,
    props,
    onSuccess,
    onError,
}: ClipboardProps): JSX.Element;

export default Clipboard;

Additional Details

  • Last updated: Fri, 15 Dec 2023 1942 GMT
  • Dependencies: @types/react

Credits

These definitions were written by Huy Tran.