Sublime Forum

Improve Goto Definition function

#1

I’ve just added Goto Definition support for the Syntax Highlighting for Sass Package. Then I noticed that I might found a few bugs of the Goto definition function.

  1. If two words are joined by hyphen, like this “two-word”. Goto Definition will only work if ( { : \s behind it such as two-word() two-word{} two-word] two-word: two-word (space), but won’t work if a semicolon ; behind it.

  2. Any word at the end of a line will not work. For example:

any_word // new link
Add a space behind can make it work.

  1. In my *.tmPreferences file, I tried to do this
<key>symbolIndexTransformation</key>
<string>s/^(?!\=)/@mixin/</string>

so there will be a @mixin hit in the Goto Symbol in Project list. But when I select a mixin name and Goto Definition, I need to manually select @mixin as well. Is it possible to ignore the content which is added by symbolIndexTransformation?

I am using Sublime Text 3 build 3047 on Mac.

Thank you :smile:

0 Likes