-
nodejs和express的Restful路由:Pleiades
资源介绍
昴
安装
npm install express pleiades
用法
/app.js :
var app = require ( 'express' ) ( ) ,
pleiades = require ( 'pleiades' ) ;
var settings = {
orm : "mysql://user:password@localhost/database" ,
objectsFolder : __dirname + '/objects' ,
} ;
pleiades ( app , settings , function ( ) {
// All objects are loaded, start serveur
app . listen ( 8000 ) ;
} ) ;
你只需要替换:
您的 orm 设置(基于)
对象目录的路径