SublimeText / Sass

Sass and SCSS syntax for Sublime Text
https://packagecontrol.io/packages/Sass
MIT License
51 stars 8 forks source link

(Goto) Symbol/Definition for variables? #28

Closed braver closed 5 years ago

braver commented 6 years ago

Right now the symbol list shows all selectors. I never found this to be very useful. Instead, I would suggest changing it to list the variables and mixins. This would allow you to quickly jump to their definitions. Of course such a change has a lot of impact, so if someone reads this and want to have a say in it, you're welcome!

michaelblyons commented 6 years ago

Three comments:

braver commented 6 years ago

Yeah, for CSS being able to find a selector that way can be nice, but you can use search for that as well. And if you lean on nested selectors a lot (and you should), the usefulness drops pretty hard. I think the important part for Sass is to be able to jump to mixin and variable definitions, that’s what I want to get working with this.

braver commented 5 years ago

In 2.2.2 the symbol list now includes mixins and functions and restores the Goto feature for them. Variables aren't usually included in the symbol list so I'm leaving them out for now. If anyone has more ideas about this let me know.

braver commented 5 years ago

I think I'm going to keep it as it is. The local symbol list shows selectors, with their indentation so you can see their nesting. The global symbol list allows you to jump to the definition of mixins, which is super useful. I don't think other syntaxes support "goto variable definition", and that might just add a lot of noise.