-
Notifications
You must be signed in to change notification settings - Fork 8
Open
Description
Hi! I wrote a react-multi-toggle.d.ts file to define the props of this component so Typescript can do static type-checking on the props. I thought I'd share it, to potentially be added to the module, or for the benefit of anyone who wants to yoink it from here.
declare module 'react-multi-toggle' {
import * as React from "react";
export interface ReactMultiToggleOption<T> {
value: T;
displayName?: string;
optionClass?: string;
}
interface ReactMultiToggleProps<T> {
options: ReactMultiToggleOption<T>[];
selectedOption: T;
onSelectOption: (value: T) => any;
label?: any;
className?: string;
}
export default class MultiToggle<T> extends React.Component<ReactMultiToggleProps<T>> {
}
}
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels