JSPM

  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 11374
  • Score
    100M100P100Q113378F
  • License MIT

Test whether a module is available as a dependency

Package Exports

  • module-available

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (module-available) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

module-available

Test whether a module is available as a dependency

Installation

$ npm install module-available

API

var moduleAvailable = require("module-available");
moduleAvailable(moduleName) -> boolean
  • moduleName - Same string with a module's name that can be passed to require. This should be a module from node_modules.

Returns true if and only if the requested module is available to be required. Otherwise returns false.

License

MIT