intro
deepjs comes with few natives protocols :
js
Simple protocol that use current or preferred (typically requirejs (browser side) and nodejs require) to load ASYNCHRONOUSLY javascript ressources (AMD module).
Warning if you use almond (or any light shim loader) to load requirejs optimiser output (i.e. you use a static AMD shim loader), you could not use this protocols anymore (there is no more way to dynamically load js files).
deep.nodes("js::deepjs/lib/unit")
.log()
instance
Same than js:: except that ressource need to be javascript Class (a function) that will be instanciate (with no arguments sent to constructor) before injection in promise.
deep.nodes("instance::/path/to/your/class.js")
.log();
this
Inner inheritance. Used in backgrounds only. (see backgrounds and flatten)
deep.nodes({
a:{
hello:"world"
},
b:{
test:12
},
c:{
_backgrounds:["this::../a", "this::/b"]
}
//...
})
.flatten()
.query("./c")
.log(); // will print : { hello:"world", test:12 }
dummy
Just there to make test or demo.
deep.nodes("dummy::hello").log();
eval
Warning Doesn't work in paranoiac environnements (as Adobe Air)
deep.nodes("eval::true").log();
dq
Native sheets protocol.
For more details on sheets, see sheets.