rootat
TypeScript icon, indicating that this package has built-in type declarations

1.1.0 • Public • Published

ReRoot

This library is designed to limit the require path in the specific directory

Intall

npm install rerootat

Usage

// Where the cloest node_modules isa
require('reroot').project_root;

// Assign where does the root '/' start from
require('reroot').search_root = "/PATH/YOU/WANT/TO/START";

// Locate and load module starts from path location you specified previously
require('@/a/b/c'); // This will load module at "/PATH/YOU/WANT/TO/START/a/b/c"

Readme

Keywords

Package Sidebar

Install

npm i rootat

Weekly Downloads

0

Version

1.1.0

License

ISC

Unpacked Size

3.01 kB

Total Files

4

Last publish

Collaborators

  • jcloudyu