文件名称:Node.js框架Kiss.js.zip
文件大小:29KB
文件格式:JS
更新时间:2022-08-08 01:39:15
开源项目
Kiss.js 是 Node.js 的 web 框架,使用 CoffeeScript 编写,简单而带感。Kiss 是面向对象的 Node.js 框架。 示例: kiss = require "kiss.js" controllers = require "../controllers/controllers" args = process.argv.splice 2 address = "127.0.0.1" port = 1337 if args[0] address = args[0] if args[1] port = parseInt args[1] my_controller = new controllers.MyController() options = application: address: address || "127.0.0.1" port: port || 1337 views: static_path: __dirname "/../views/static/" template_path: __dirname "/../" locale_path: __dirname "/../views/locales/" cookie_secret: "ertyu78f020fk" urls: "/": my_controller "/user": "/posts": my_controller app = new kiss.core.application.Application(options) app.start() 标签:Kissjs
【文件预览】:
wheels-master
----bin()
--------kiss.coffee(2KB)
--------kiss.js(82B)
----index.js(165B)
----license.txt(2KB)
----package.json(932B)
----readme.md(2KB)
----test()
--------1.core.application.coffee(632B)
--------3.controllers.router.coffee(444B)
--------2.core.eventer.coffee(659B)
--------4.views.text_viewer.coffee(464B)
----examples()
--------pdf()
--------chat()
----.gitignore(22B)
----lib()
--------core()
--------controllers()
--------views()
----project()
--------core()
--------index.js(58B)
--------controllers()
--------views()