mirror of
https://github.com/pulsar-edit/pulsar.git
synced 2024-08-16 14:40:23 +03:00
[language-gfm] Make each block-level HTML tag its own injection…
…which, surprising as it sounds, has a _huge_ performance benefit.
This commit is contained in:
parent
6d36685df3
commit
3d70f62953
@ -23,13 +23,11 @@ exports.activate = () => {
|
||||
languageScope: null
|
||||
});
|
||||
|
||||
// Create one HTML injection layer for all block-level HTML nodes.
|
||||
// A separate injection layer for each block-level HTML node.
|
||||
atom.grammars.addInjectionPoint('source.gfm', {
|
||||
type: 'document',
|
||||
type: 'html_block',
|
||||
language: () => 'html',
|
||||
content(node) {
|
||||
return node.descendantsOfType('html_block');
|
||||
},
|
||||
content: (node) => node,
|
||||
includeChildren: true
|
||||
});
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user