Skip to content

[bug]: Installation fails of react-day-picker with Nextjs 15 #2559

@GeorgeMapili

Description

@GeorgeMapili

Summary

An error occurs when attempting to install the react-day-picker package in a newly created Next.js 15.0.1 project, due to a dependency conflict with React.

Code

How to reproduce.

1. Create a new Nextjs project
npx create-next-app@latest

2. Select the default options

3. Try to initialize the react-day-picker
npm i react-day-picker

4. The installation fail during the package installation with this following error

npm error ERESOLVE unable to resolve dependency tree
npm error Found: react@19.0.0-rc-69d4b800-20241021
npm error Could not resolve dependency:
npm error peer react@">=16.8.0" from react-day-picker@9.2.0

Environment

Nextjs version: 15.0.1
React version: 19.0.0-rc-69d4b800-20241021,
npm version: 10.8.2
node version: v20.17.0

Expected Behavior

The react-day-picker package should install successfully without dependency conflicts.

Actual Behavior

The installation fails due to a version conflict. react-day-picker@9.2.0 requires a peer dependency of react@">=16.8.0", which does not resolve with the specified React version (19.0.0-rc-69d4b800-20241021) in the Next.js 15.0.1 environment.

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