Reputation: 21
Module not found: Can't resolve './reducers/index' in'C:\Users\Dibba\Desktop\rdx\src' This error occurred during the build time and cannot be dismissed.
node version is v9.11.2 npm version is 6.9.1-next.0
structure:
error message :
code:
Upvotes: 2
Views: 6799
Reputation: 29
You have to remove the /index from the directory './reducers/index' and set it to './reducers'. It should work.
If the above does not work for you, check the steps below.
Make sure the reducers folder is created in the 'src' directory and create a file named index.js in the reducers folder.
Upvotes: 0
Reputation: 51
Your app is not able to find your root reducer since the file name on disk doesn't match the file name in the code. There appears to be a trailing space in the filename of ./reducers/index.js
, from what I can see in your first screenshot. Remove the space and your app should be able to find the file without problem.
Upvotes: 5