@each directive and url definition

I use each rule and Webstorm considers this as an error, because literally it cannot find '$(val).svg' in assets directory.

 

Is there any way I can fix this?

 

 

5 comments
Comment actions Permalink

You can suppress the error with a comment, like:

//noinspection CssUnknownTarget
background: url("./assets/$(val).svg")
0
Comment actions Permalink

So IDE cannot resolve this by any chance?

0
Comment actions Permalink

sure it can't, it won't evaluate your code when trying to resolve paths

0
Comment actions Permalink

Maybe there is one global config where I can handle such kind of situations? Because writing each time a comment is clearly not the best solution.

0
Comment actions Permalink

No; you can only disable the CSS | Invalid elements | Unknown file or directory inspection in Settings | Editor | Inspections

0

Please sign in to leave a comment.