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 we only store the last range for the specifier in the graph. This makes it difficult when trying to rewrite specifiers (like in dnt or deno vendor) as well as means that diagnostics are only issued for the "last" import location, not all import locations for a given specifier.
We should enhance the graph to be able to store this information, which is likely going to be a breaking change, but one that increases the usability of the graph.
The text was updated successfully, but these errors were encountered:
I've run into needing this for deno vendor again while working on the import map only solution. It also needs to know the text for the // @deno-types="..." and /// <reference types="..." /> directives so that it can tell if it needs to map those.
Currently the graph cannot represent multiple locations an import specifier might be imported in a file. For example, an import can be like this:
In addition, in theory, a module can be statically and dynamically imported:
Or in TypeScript the same specifier can be provided for a type only import:
Currently we only store the last range for the specifier in the graph. This makes it difficult when trying to rewrite specifiers (like in dnt or
deno vendor
) as well as means that diagnostics are only issued for the "last" import location, not all import locations for a given specifier.We should enhance the graph to be able to store this information, which is likely going to be a breaking change, but one that increases the usability of the graph.
The text was updated successfully, but these errors were encountered: