package-require

1.0.0 • Public • Published

package-require Build Status

Installation

npm install --save package-require

Usage

Require Node.js modules relative to the root of your project. Directories are scanned starting from the current module, towards the root directory, until the root of your project found. The root of your project is considered to be the closest one with a package.json file. Files outside the root of your project cannot be loaded, even if you try loading them with ../../.

const pr = require('package-require');
pr(module, 'lib/my-js-module');

Package Sidebar

Install

npm i package-require

Weekly Downloads

0

Version

1.0.0

License

MIT

Unpacked Size

6.27 kB

Total Files

6

Last publish

Collaborators

  • joshuawise