vscode-cfml icon indicating copy to clipboard operation
vscode-cfml copied to clipboard

Auto-close HTML tag inside CFML string performance issue

Open redtopia opened this issue 6 years ago • 1 comments

When creating an HTML tag within a CFML string, I'm noticing that performance can be a problem, specifically and consistently in larger .cfm or .cfc files. In one case, I have a .cfc file that is 7500 lines long. When adding HTML markup to a string in this file, the auto-close feature takes long enough that it can affect the position of the caret well after the edit has taken place.

The editor actions that occur when starting an HTML tag inside a CFML string are 1) create the end tag, and 2) move the caret in between the start/end tags.

As you can see by the following screencast, each action takes a couple seconds. Many times the lag time is substantially longer.

screenshot

The time it takes to perform these auto-close actions can range from instantaneous, to many seconds. I'm not sure what conditions cause the lag, but I assume it has to do with parsing.

When this lag occurs, the caret can be re-positioned well after I am done editing the markup, and when I'm editing something else.

I understand that auto-closing tags uses the Auto Close Tag extension (https://github.com/formulahendry/vscode-auto-close-tag). Is it possible that relying on this extension is problematic in terms of performance?

redtopia avatar Jun 17 '19 19:06 redtopia

Looks like there are lots of performance issues with the Auto Close Tag extension: https://github.com/formulahendry/vscode-auto-close-tag/issues

redtopia avatar Jun 17 '19 19:06 redtopia