jspm-resolve
v2.1.0
Published
A module resolver for jspm packages
Downloads
1,359
Readme
jspm-resolve
A module resolver that locates jspm packages using resolve.
Installation
npm install --save-dev jspm-resolve
Parameters
jspm-resolve
takes the same parameters as resolve, plus these:
pathsOverride
: (Object) Override paths set in your jspm config file.rootDir
: (String) Specify a custom jspm root directory (relative to your project's root).
Asynchronous use
import resolve from "jspm-resolve";
resolve("react", {}, (err, result) => {
if (err) {
throw err;
}
console.log(result) // path to jspm react
});
Synchronous use
import resolve from "jspm-resolve";
const result = resolve.sync("react", {});
console.log(result) // path to jspm react
License
MIT