Skip to content

Commit

Permalink
fix(syntaxes): Do not apply block syntax highlighting to JS and CSS i…
Browse files Browse the repository at this point in the history
…n templates (#1952)

This commit excludes the block syntax highlighting from JS and CSS
scopes in templates. This would include `script` and `style` tags.
  • Loading branch information
atscott authored Dec 5, 2023
1 parent 487c13a commit abfdaa7
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion syntaxes/src/template-blocks.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ import {GrammarDefinition} from './types';

export const TemplateBlocks: GrammarDefinition = {
scopeName: 'template.blocks.ng',
injectionSelector: 'L:text.html -comment -expression.ng -meta.tag',
injectionSelector: 'L:text.html -comment -expression.ng -meta.tag -source.css -source.js',
patterns: [
{include: '#block'},
],
Expand Down
2 changes: 1 addition & 1 deletion syntaxes/template-blocks.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"scopeName": "template.blocks.ng",
"injectionSelector": "L:text.html -comment -expression.ng -meta.tag",
"injectionSelector": "L:text.html -comment -expression.ng -meta.tag -source.css -source.js",
"patterns": [
{
"include": "#block"
Expand Down

0 comments on commit abfdaa7

Please sign in to comment.