You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
You'll get an error like the following, and see that it can be fixed by downgrading to React 18.
src/App.tsx:36:8 - error TS2786: 'ImageGallery' cannot be used as a JSX component.
Its type 'typeof ReactImageGallery' is not a valid JSX element type.
Type 'typeof ReactImageGallery' is not assignable to type 'new (props: any) => Component<any, any, any>'.
Construct signature return types 'ReactImageGallery' and 'Component<any, any, any>' are incompatible.
The types returned by 'render()' are incompatible between these types.
Type 'import("/home/janie/git/janie.page/photo-gallery/node_modules/@types/react-image-gallery/node_modules/@types/react/index").ReactNode' is not assignable to type 'React.ReactNode'.
Type 'ReactElement<any, string | JSXElementConstructor<any>>' is not assignable to type 'ReactNode'.
Property 'children' is missing in type 'ReactElement<any, string | JSXElementConstructor<any>>' but required in type 'ReactPortal'.
36 <ImageGallery items={images} slideInterval={10000} showNav={false} />
The text was updated successfully, but these errors were encountered:
Steps to reproduce the behavior:
ImageGallery
with a React 19 repo.The text was updated successfully, but these errors were encountered: