Element $variable is resolved only by name without use of explicit in Sass PhpStorm

No, you’re doing it correctly. Have one main.scss file and make sure your variables are the first thing that you import (otherwise you will run into undefined variable issues in other files). You do not need to re-import your variables for each file as long as they are all included in your main.scss file.

I normally ignore this PhpStorm error, or you can turn it off:

  • Go to File -> Settings
  • Editor -> Inspections in the left panel
  • Sass/SCSS in the right panel
  • uncheck Missing import (or Resolved by name only on older versions)

Leave a Comment

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)