Skip to content

React 19 support #877

@franknoel

Description

@franknoel

After upgrading to React 19, the useCountUp hook started to throw a TypeScript warning.

Type 'RefObject<HTMLElement | null>' is not assignable to type 'string | RefObject<HTMLElement>'.
  Type 'RefObject<HTMLElement | null>' is not assignable to type 'RefObject<HTMLElement>'.
    Type 'HTMLElement | null' is not assignable to type 'HTMLElement'.
      Type 'null' is not assignable to type 'HTMLElement'.ts(2322)

Adding support for React 19 and generating new types should fix the issue.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions