Skip to content

elixiao/power-require

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

power-require

const superRequire = require('power-require')
const a = superRequire.fromFile('path/to/file','whatever/node/module/path/you/want')

API

fromFile(file, [folder])

file

Required
Type: string

where file is located, either absolute or relative path is supported.

folder

Type: string
Default: .

from where to find module path, default is the path of the requiring parent file

About

require commonjs module from string or file

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published