Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cannot find module: 'lodash.isequalwith' #5942

Closed
guilbill opened this issue Feb 22, 2021 · 4 comments
Closed

Cannot find module: 'lodash.isequalwith' #5942

guilbill opened this issue Feb 22, 2021 · 4 comments
Labels

Comments

@guilbill
Copy link
Contributor

What you were expecting:

When following the tutorial to this point I want the app to build and run properly when running yarn start, as described in the doc.

What happened instead:

The build failed with the message :

./node_modules/connected-react-router/esm/ConnectedRouter.js
Module not found: Can't resolve 'lodash.isequalwith' in '/react-admin/node_modules/connected-react-router/esm'

Steps to reproduce:

Create new react app :

yarn create react-app test-admin
cd test-admin/
yarn add react-admin ra-data-json-server prop-types

Change App.js as follow:

// in src/App.js
import * as React from "react";
import { Admin } from 'react-admin';
import jsonServerProvider from 'ra-data-json-server';

const dataProvider = jsonServerProvider('https://jsonplaceholder.typicode.com');
const App = () => <Admin dataProvider={dataProvider} />;

export default App;

Related code:

https://github.com/guilbill/tuto-react-admin

Other information:

It is related with a bug on connected-react-router : supasate/connected-react-router#480

Environment

  • React-admin version: 3.12.4
  • React version: 17.0.1
  • Browser: Brave Version 1.19.90 Chromium: 88.0.4324.146
  • Stack trace (in case of a JS error):

./node_modules/connected-react-router/esm/ConnectedRouter.js
Module not found: Can't resolve 'lodash.isequalwith' in '/react-admin/node_modules/connected-react-router/esm'
@djhi
Copy link
Collaborator

djhi commented Feb 22, 2021

So it's because we have a dependency on connected-react-router with a ^.

@fzaninotto fzaninotto added the bug label Feb 22, 2021
@fzaninotto
Copy link
Member

This is a critical bug. We'll wait a day to see if the connected-react-router team fix it on their side, and release a bugfix if they don't.

In the meantime, please use resolutions in packages.json to force the version of connected-react-router used by react-admin.

// in packages.json
{
   // ...
   "resolutions": {
      "connected-react-router': "6.6.1",
    }
}

@ltnscp9028
Copy link

@fzaninotto I make connected-react-router PR. supasate/connected-react-router#481
The relevant PR must be merged urgently.

@fzaninotto
Copy link
Member

connected-react-router@6.9.1 was just released (https://github.com/supasate/connected-react-router/releases/tag/v6.9.1). I tested that the bug no longer occurs.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

4 participants