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
Describe the bug
When adding the following line:
import DatePicker from "react-datepicker";
I am getting the following error:
Cannot assign to read only property 'isEqual' of object '#'
To Reproduce
Steps to reproduce the behavior:
My component:
import React from 'react';
import DatePicker from "react-datepicker";
export class App extends React.Component {
render() {
return (
Test
);
}
}
export default App;
I am using Node 20, webpack 5, and babel.
Expected behavior
Expected behavior is it to work as expected.
Screenshots
Additional context
Additional information seems to be choosing the commonjs instead of the esm version of date-fns. When I manually move over the code from the cjs file to the js file it works. But out the box it is choosing the wrong one.
My package.json has "type": "module".
Thanks for the help.
The text was updated successfully, but these errors were encountered:
@wmillerjjk Can you plz share version of react & react-datepicker. Make sure the versions of react-datepicker and date-fns are compatible. Check the peerDependencies section in the react-datepicker documentation
Describe the bug
When adding the following line:
import DatePicker from "react-datepicker";
I am getting the following error:
Cannot assign to read only property 'isEqual' of object '#'
To Reproduce
Steps to reproduce the behavior:
My component:
import React from 'react';
import DatePicker from "react-datepicker";
export class App extends React.Component {
render() {
return (
);
}
}
export default App;
I am using Node 20, webpack 5, and babel.
Expected behavior
Expected behavior is it to work as expected.
Screenshots
Additional context
Additional information seems to be choosing the commonjs instead of the esm version of date-fns. When I manually move over the code from the cjs file to the js file it works. But out the box it is choosing the wrong one.
My package.json has "type": "module".
Thanks for the help.
The text was updated successfully, but these errors were encountered: