-
This is the load module package of NodeJs, which is evolved from the core module of NodeJs. Define the members in the module which need to be exporetd by expors, that is exposed to other modules for use。ways like below:
-
a.js
var mr = require('mr') //It returns an object mr('./b.js') //The value and object defined in exprots are returned
-
b.js
exports = 123 exports = funcyion(){ console.log('hello') }
-
It also has disadvantages like how to avoid been overridden, The final completion looks like a defining member exposed to the file domain.
-
Notifications
You must be signed in to change notification settings - Fork 0
namexi/node
Folders and files
Name | Name | Last commit message | Last commit date | |
---|---|---|---|---|
Repository files navigation
About
mr加载模块
Resources
Stars
Watchers
Forks
Releases
No releases published
Packages 0
No packages published