casesandberg / casesandberg/react-color
onChangeCompleteHandler parameter is not typed
- Dominant language
- JavaScript
- Stars
- 12.3k
- Forks
- 920
- PR merge metrics
- No merged PRs in 30d
Description
Hi,
I'm using this component in my React App with Typescript. The linter gives me an error saying the color parameter needs to have a type. I've tried `any `and `unknown `but it just gives one problem or the other. Appreciate it if there is a type for this.
```
const onChangeCompleteHandler = (color: unknown) => {
}
```
Contributor guide
Research direction
Start from the React component API and the onChangeCompleteHandler callback shown in the issue, then inspect how its color argument is exposed to TypeScript consumers. Verify the callback type in a small TypeScript usage example; done means the linter accepts the handler without any or unknown.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- react, typescript
- Domain
- frontend
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100