【文件属性】:
文件名称:http-tasker:HTTP触发任务服务器的NodeJS模块
文件大小:3KB
文件格式:ZIP
更新时间:2021-05-23 17:43:15
JavaScript
http-tasker是使用http模块的超小型轻量级任务处理服务库。 它的主要用途是提供将URL路径映射到函数的快捷方式。 对于API构建,调度脚本等有用。
安装
npm install http-tasker
例子
该库的使用非常简单:
var httpTasker = require ( 'http-tasker' ) ;
httpTasker . createServer ( {
'/test' : function ( ) { // Requests made to the path '/test' will trigger this
// The initialization function - perform any setup here
return function ( method , query , requestBody ) { // Return
【文件预览】:
http-tasker-master
----test.js(477B)
----LICENSE(1KB)
----README.md(2KB)
----index.js(936B)
----package.json(269B)