Skip to content

Improve VSCode default comment function behavior#47

Merged
liyao001 merged 1 commit intobioSyntax:masterfrom
alanhoyle:master
Mar 7, 2019
Merged

Improve VSCode default comment function behavior#47
liyao001 merged 1 commit intobioSyntax:masterfrom
alanhoyle:master

Conversation

@alanhoyle
Copy link
Contributor

Currently, any bioSyntax files within VSCode default to having the "Toggle Line Comment" function add a "//" at the beginning of the line, and the "Toggle Block Comment" encloses the selection in "/* ... */".

This change disables block comments and changes the Toggle Line Comment to use "#" which is much more common in these types of files.

Currently, any bioSyntax files within VSCode default to having the "Toggle Line Comment" function add a "//" at the beginning of the line, and the "Toggle Block Comment" encloses the selection in "/* ... */".  

This change disables block comments and changes the Toggle Line Comment to use "#" which is much more common in these types of files.
Copy link
Contributor

@liyao001 liyao001 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great! I'll update the VSCode plugin later today.

@liyao001 liyao001 merged commit 2f47af8 into bioSyntax:master Mar 7, 2019
@alanhoyle
Copy link
Contributor Author

alanhoyle commented Mar 7, 2019

There might be a tiny bug here:

While trailing commas are allowed in JavaScript, apparently, they're not supposed to be allowed in JSON objects. The patch works when I put it in place, but it might be better if the trailing comma was removed.

@alanhoyle
Copy link
Contributor Author

It appears that the JSON interpreter in VSC handles trailing commas and comments just fine, so no need to worry unless they change the interpreter. .

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants