For example, if a definition for tag <my-component> is available and passed to the helper, the helper should provide completion for it for cases like
<my-comp|
I don't know if it's viable to pass through the list to doComplete each time, because the list could be huge. Some Vue UI library provides hundreds of custom tags (Quasar, Element).
A better approach might be having a stateful CompletionProvider class that exposes a method for adding tag definitions.
Related: https://github.com/vuejs/vetur/issues/656
Ideally, the helper library could take a list of tag definitions (similar to
HTMLTagSpecification
in https://github.com/Microsoft/vscode-html-languageservice/blob/master/src/parser/htmlTags.ts) and allow tag completion with those custom tags.For example, if a definition for tag
<my-component>
is available and passed to the helper, the helper should provide completion for it for cases likeI don't know if it's viable to pass through the list to
doComplete
each time, because the list could be huge. Some Vue UI library provides hundreds of custom tags (Quasar, Element). A better approach might be having a statefulCompletionProvider
class that exposes a method for adding tag definitions.