Eugen
Eugen

Reputation: 2990

Make WebStorm see the paths

I do have an Electron + React project which I inherited from another developer. in the index.js there are a couple of imports that WebStorm is saying it cannot find, however, the application compiles and works as needed.

enter image description here

and here is the structure of the folders relative to index.js

enter image description here

How do I make WebStorm happy and make it see the imports and navigate properly to them? I tried to use exports section in the package.json like this

"exports": {
    "./": "./src/"
  }

but it didn't help. Any other options?

Upvotes: 0

Views: 32

Answers (1)

s0xzwasd
s0xzwasd

Reputation: 3224

Right-click on src directory and select Mark Directory as | Resource Root.

Upvotes: 2

Related Questions