You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi @muenzpraeger
Thanks a lot for your PR. I really appreciate your contribution. Could you please extend your description a bit more and help me understand the exact problems this PR solves?
be autodetected for .amp files
In the current version, if you open an amp file, it will automatically enable ampscript syntax highlighting. But it feels like your PR helps to do smth else.
apply syntax highlighting also when AMPscript is used outside of a block statement
Right now extension supports block (%%[...]%%) and inline (%%==%%) ampscript
The autodetection (aka: property fileTypes) is meant to be for cases when a language can't be autodetected (see 12.1, 2nd bullet here). It's part of the grammar spec. That's less a thing for VS Code itself, and more a general practice.
The other part (apply syntax highlighting) is so that syntax highlighting is even applied when AMPscript is not inline/block (sorry for being clear).
Like when you build some AMP within an .amp file, you'll always have to have it enclosed as block/inline, otherwise it's not highlighted.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR extends the AMPscript TextMate definitions to:
.ampfiles