Skip to content

ERROR: “Module not found: Can’t resolve” when importing custom component, but the path is 100% correct?

I’m getting this error trying to import a custom component, but my path is correct?

Failed to compile. ./src/component/Footer/Footer.component.js
Module not found: Can’t resolve
‘/scandipwa/src/component/FooterLinks’
in
‘/scandipwa/src/component/Footer’

But the path is correct?

Here’s a view of my file structure and my imports – “FooterLogo” and “FooterTagline” are working fine, just not “FooterLinks” and they are all in the same path.

enter image description here

I’ve also added the path using autocomplete in VS Code. It is 100% correct, but the error persists?

What could be causing this?