Created
October 23, 2022 07:19
-
-
Save koss-lebedev/38afa26ddc83c1940ff9f041de428a08 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
type Props = HTMLAttributes<HTMLInputElement> | |
const CustomInput = ({ onChange, ...props }: Props) => { | |
const handleChange = (event) => { | |
/// ... some logic | |
onChange(event) | |
} | |
return <input {...props} onChange={handleChange} /> | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment