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 resolving a context for the language service requires calling ts.preProcessFile on all files in the context, and following references. resolving triple-slash references is simple, resolving modules is a bit more complicated, as it involves searching in containing directories until a matching .ts file is found.
Something that is currently missing, and should be added in next release, is a built-in way to resolve imports. ts.preProcessFile returns import text, and the caller needs to resolve that to a .ts file path. Issue #1793 tracks fixing it.
@mhegazy Is there updated documentation that shows how this can be done? I'm looking to implement some custom module-resolution logic. I have it working with tsc, but I'd like the IDE to be able to resolve these modules as well without them showing up as errors.
@mhegazy Is there updated documentation that shows how this can be done? I'm looking to implement some custom module-resolution logic. I have it working with tsc, but I'd like the IDE to be able to resolve these modules as well without them showing up as errors.
currently resolving a context for the language service requires calling
ts.preProcessFile
on all files in the context, and following references. resolving triple-slash references is simple, resolving modules is a bit more complicated, as it involves searching in containing directories until a matching .ts file is found.As a work around, here is the resolution logic:
The text was updated successfully, but these errors were encountered: