You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Currently, html language services use the javascript language service by directly including an instance of the latter. However, for issues such as #130, this would require an instance of CSS LS in HTML, and the vice versa. These dependencies make each LS inter-dependent and hard to understand.
With #800, we can also have a top-level document MetadataSore that consumes FileService and provide up-to-date metadata that's generated from a particular language service, for example:
File change happens on a file's style region
CSS LS re-parses style region
All class names are stored under css.classes for that file
Later the user triggers html class completion
HTML LS determines it's a class name completion request
metadataStore.getMetadata(doc.uri)["css.classes"] will have the relevant data
Use those data to generate completions
Another place that can be simplified is the current findComponents, which provides component intellisense based on the shape of each of the depended components.
Benefits
Generation of metadata is event-based instead of LSP-feature triggered. This will likely make processing LSP feature faster since some parsing work will have been finished during the language feature request timeframe.
Motivation
Currently, html language services use the javascript language service by directly including an instance of the latter. However, for issues such as #130, this would require an instance of CSS LS in HTML, and the vice versa. These dependencies make each LS inter-dependent and hard to understand.
With #800, we can also have a top-level document
MetadataSore
that consumesFileService
and provide up-to-date metadata that's generated from a particular language service, for example:style
regionstyle
regioncss.classes
for that fileLater the user triggers html class completion
metadataStore.getMetadata(doc.uri)["css.classes"]
will have the relevant dataAnother place that can be simplified is the current
findComponents
, which provides component intellisense based on the shape of each of the depended components.Benefits
The text was updated successfully, but these errors were encountered: