Skip to content

Widen @tanstack/react-charts peer dependency to React 18 and 19 #130

Description

@toomingos

Version: @tanstack/react-charts 0.16.0.

@tanstack/react-charts declares react: ^19.0.0 and react-dom: ^19.0.0 as peers. Reading the adapter, it uses only hooks available since React 18 (useRef, useMemo, useLayoutEffect, useState, useId, useCallback, memo, forwardRef) and no React 19-only APIs (use, useActionState, useOptimistic, ref-as-prop). Libraries that wrap the adapter and still support React 18 consumers currently fail peer resolution.

Would it be possible to set the peer to ^18.0.0 || ^19.0.0 (and react-dom likewise), with a CI matrix entry for 18, unless there is a React 19 requirement I have missed?

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions