Node.js MVC 框架 Paloma

码农软件 · 软件分类 · JavaScript MVC 框架 · 2019-03-15 14:13:25

软件介绍

Paloma 是一个类 Angular 的 Node.js MVC 框架。

特性:

  • 依赖注入

  • 基于 koa@2

例子:

'use strict';

const Paloma = require('paloma');
const app = new Paloma();

app.controller('indexCtrl', function (ctx, next, indexService) {
  ctx.body = `Hello, ${indexService.getName()}`;
});

app.service('indexService', function () {
  this.getName = function () {
    return 'paloma';
  };
});

app.route({
  method: 'GET',
  path: '/',
  controller: 'indexCtrl'
});

app.listen(3000);

本文地址:https://codercto.com/soft/d/1404.html

Introduction to Computer Science Using Python

Introduction to Computer Science Using Python

Dierbach, Charles / 2012-12 / $ 133.62

Introduction to Computer Science Using Python: A Computational Problem-Solving Focus introduces students to programming and computational problem-solving via a back-to-basics, step-by-step, objects-la......一起来看看 《Introduction to Computer Science Using Python》 这本书的介绍吧!

JS 压缩/解压工具
JS 压缩/解压工具

在线压缩/解压 JS 代码

CSS 压缩/解压工具
CSS 压缩/解压工具

在线压缩/解压 CSS 代码

正则表达式在线测试
正则表达式在线测试

正则表达式在线测试