resolve_import_path
Resolves a given path based on the repository structure to the working directory. Good for determining the path of imports and such.
Arguments
Name
Type
Description
Required
path_to_resolve
string
The path to resolve based on the repository structure.
reference_path
string
The path to use as the reference for resolution. Likely the path to the file where the path to resolve is used.
preferred_extensions
array
List of preferred file extensions to check for the path to resolve.
Returns
Type
Description
string
The resolved path relative to the working directory.
Example
Last updated