0.0.19 • Published 10 years ago
requireasync v0.0.19
requireasync
usage
if(!window)var window=eval(require('requireasync').install);else var node=false,browser=true;
REQUIRE(
["fs", "path.resolve"],
function (err, fs, resolve) {
fs.readFile(resolve(".","readme,md"),function(err,data){
console.log(err,data);
})
}
)
Shorthand: $R$ can be substituted for REQUIRE
Try this for an instant load and run one liner:
console.log($R$({path:"resolve"})(".","myfile.js"));
See the html folder for a working demo.
change to that folder and type
$ npm install .
$ node demo.js
To load the demo server, and it will give you a local browser url along the lines of
visit http://localhost:8080/index.html to demo the browser files
0.0.19
10 years ago
0.0.18
10 years ago
0.0.17
10 years ago
0.0.16
10 years ago
0.0.15
10 years ago
0.0.14
10 years ago
0.0.13
10 years ago
0.0.12
10 years ago
0.0.11
10 years ago
0.0.10
10 years ago
0.0.9
10 years ago
0.0.8
10 years ago
0.0.7
10 years ago
0.0.6
10 years ago
0.0.5
10 years ago
0.0.4
10 years ago
0.0.3
10 years ago
0.0.2
10 years ago
0.0.1
10 years ago