HTML-CSS-Class-Completion
HTML-CSS-Class-Completion copied to clipboard
Use activiation events to prevent running the extension on unexpected workspaces
Instead of listening to everything https://github.com/zignd/HTML-CSS-Class-Completion/blob/749536f81de5f6ec0ba54c7d3e769d91d21f424c/package.json#L21-L23
we could use something like:
"activationEvents": [
"onLanguage:css",
"workspaceContains:**/*.css"
],
which will only start the extension when there are css files on the entire workspace(including subfolders) or a css file is going to be created.
This will save memory and unneeded cpu usage.
(extracted from https://github.com/zignd/HTML-CSS-Class-Completion/issues/114#issuecomment-364691510)