0.24.0 • Published 6 years ago
web-host v0.24.0
If you want to define a web site that can run alongside other web sites, web-host can help you do that.
Demo
var library = require("module-library")(require)
library.using(
["./", "web-element"],
function(host, element) {
host.onRequest(function(getBridge) {
var bridge = getBridge()
bridge.send("Hello, world")
})
host.onSite(function(site) {
site.addRoute(
"get",
"/bye",
function(request, response) {
response.send("Y'all have a nice day now")
}
)
})
// site should be started now. check your terminal for the address
}
)
0.24.0
6 years ago
0.23.0
7 years ago
0.22.0
7 years ago
0.21.0
7 years ago
0.20.0
7 years ago
0.19.0
7 years ago
0.18.0
7 years ago
0.17.0
7 years ago
0.16.0
7 years ago
0.15.0
7 years ago
0.14.0
7 years ago
0.13.0
7 years ago
0.12.0
7 years ago
0.11.0
7 years ago
0.10.0
7 years ago
0.9.0
7 years ago
0.8.0
7 years ago
0.7.0
7 years ago
0.6.0
7 years ago
0.5.0
7 years ago
0.4.0
7 years ago
0.3.0
7 years ago
0.2.0
7 years ago
0.1.0
7 years ago