Skip to content

Support for React 19 types in AuthProviderΒ #637

@devth

Description

@devth

Version info

React: 19

Firebase: 11.0.2

ReactFire: 4.2.3

Other (e.g. Node, browser, operating system) (if applicable): Node 20

Problem

As of this change to react/@types, reactfire no longer type checks. It errors like:

Type error: 'AuthProvider' cannot be used as a JSX component.
  Its type '(props: PropsWithChildren<{ sdk: Auth; }>) => Element' is not a valid JSX element type.
    Type '(props: PropsWithChildren<{ sdk: Auth; }>) => Element' is not assignable to type '(props: any) => ReactNode | Promise<ReactNode>'.
      Type 'Element' is not assignable to type 'ReactNode | Promise<ReactNode>'.

Expected behavior

It type checks against react 19.

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