Node.js Web 开发框架大全《中间件篇》

  这篇文章与大家分享优秀的 Node.js 中间件模块。Node 是一个服务器端 JavaScript 解释器,它将改变服务器应该如何工作的概念。它的目标是帮助程序员构建高度可伸缩的应用程序,编写能够处理数万条同时连接到一个(只有一个)物理机的连接代码。

您可能感兴趣的相关文章

  • 10大流行的 Metro UI 风格 Bootstrap 主题
  • 推荐35款精致的 CSS3 和 HTML5 网页模板
  • 让人爱不释手的精美 Web 应用程序图标素材
  • 赞!10套精美的免费网站后台管理系统模板
  • 精选12款优秀 jQuery Ajax 分页插件和教程

 

JSGI

 

  • commonlogger - A logger of HTTP requests.
  • compact - Join and compress frontend javascript.
  • compress - Gzip compresses (using node-compress) the response when appropriate based on request headers.
  • conditional - Handles conditional HTTP requests (If-Modified-Since, etc.)
  • contentlength - Sets Content-Length header.
  • csrf - Checks HTTP request for possible cross-site request forgery, flags dangerous requests.
  • extension - Transforms .extension to a RESTful Accept header
  • head - Handles HEAD requests (stripping body).
  • http-params - Converts HTTP parameters http- to headers.
  • media - Performs content type negotiation (per RFC2616) delegating to appropriate media handler.
  • redirect - Redirects to other URLs
  • rewriter - Rewrites defined paths to other paths.
  • routes - Simple RegExp based router
  • session - Session manager with pluggable storage handling
  • static - Static file handler using asynchronous streaming.
  • transporter - Share modules with browser, works RequireJS and Yabble
  • urlmap - Maps to different apps by path/URL
  • xsite - Handles JSONP, window.name, and cross-origin XHR (CORS).

Connect

 

  • connect-jade-static - Serving jade files as static html
  • aspa-express - Simple, dependency-free middleware for serving assets packaged with aspa.
  • browserify-middleware - Middleware for serving up node.js code with requires to the client.
  • bundle-up — A simple asset manager middleware for managing css and js files.
  • client-certificate-auth - Basic TLS/SSL client certificate authentication
  • connect_facebook - Facebook session support for Connect
  • connect_json - Support for parsing JSON requests and sending JSON responses in Connect
  • connect-airbrake — Airbrake error reporting auto-setup middleware
  • connect-assetmanager - Asset manager for Connect for handling CSS/JS files
  • connect-assets - Compiled CSS/JS asset pipeline inspired by Rails 3.1
  • connect-auth — Connect authentication middleware, provides out-of-the-box implementations of HTTP (Basic & Digest), Twitter, Facebook, BitBucket, Janrain, Yahoo, Sina, Google, OAuth (1.0 server), Github and a couple of others....
  • connect-compiler — Development middleware to dynamically recompile derived files at serve-time.
  • connect-dojo — Connect middleware exposing the Dojo Toolkit
  • connect-domain — Asynchronous error handler for Connect
  • connect-force-domain — force all visitors onto a single domain
  • connect-gridfs — GridFS file server for Connect
  • connect-http-signature — middleware wrapper for Joyent's HTTP Signature reference implementation
  • connect-proxy — Retrieve originating ip/host values when proxying to your connect app
  • connect-roles — Dynamic roles based authorization for connect/express, designed to work well with passport and everyauth.
  • connect-rpx - Use RPX with Node.js and Connect
  • cookie-sessions — Secure cookie-based session store
  • dispatch — Regular expression URL dispatcher
  • everyauth — Connect authentication and authorization middleware, modular, configurable, supporting password, OpenId, Google, OAuth, Twitter, LinkedIn, Yahoo, Readability, Dropbox, Justin.tv, Vimeo, Tumblr, OAuth2, Facebook, GitHub, Instagram, Foursquare, Box.net, LDAP
  • express-chromeframe — Dead simple middleware to enable chromeframe on connect/express applications.
  • express-errors — Simple error handling
  • facebook-wrapper — Basic wrapper to the Facebook API, designed to work with Connect and Express
  • form2json — Decoder for form-urlencoded data that supports arrays of nested objects
  • formaline - full-featured module for handling form POSTs/PUTs (multipart/form-data, application/x-www-form-urlencoded ) and fast parsing of file uploads, it speaks JSON and it is also ready for use with middlewares like connect.
  • http-accept — Connect compatible middleware that parses HTTP Accept header fields
  • merge-js — Simple connect middleware for merging multiple js files and uglifying the result.
  • mincer — direct Sprockets assets manager port, with middleware for connect/express
  • minj — Serve minified javascript files with Connect/Express
  • monomi — Provides tools for handling tablet, touch, and mobile browsers
  • node_signedcookies — Extends Express's cookieParser() to read/write signed cookies.
  • node-facebook-session-cookie — eats facebook cookies from client FB.login() and makes the session available as req.fb_session
  • passport — Simple, modular, and unobtrusive authentication framework for Connect and Express.
  • pound — Pound is an high-level interface for Piler - The Awesome Asset Manager for Node.js
  • quip — Chainable HTTP response API
  • resource-router — A resource-oriented router to replace the default routing in express
  • resty — Quickly and simply build REST APIs with this connect middleware
  • session-web-sockets — Pass session to (Socket.IO-node) in a secure manner. Originally forked from bmeck/session-web-sockets
  • session.js — super simple session middleware for node.js, even has optional "magic" sessions which monkey patch the httpServer with one line!
  • Shrinkroute - Named routes for Express. Helps you in achieving DRY routes!
  • trust-reverse-proxy - Trust (SSL) connections coming from (a) specific reverse prox(y)(ies)

Other middleware

 

  • bouncy — bounce HTTP requests around for load balancing or as an HTTP host router
  • buffet — Performance-oriented static file server & middleware
  • dota2api — Dota2 api wrapper written in node.js
  • eventpipe — Provides an Event Pipe with the same API as node.js' EventEmitter
  • exedra — Express routes & functions loader
  • express-debug — Express middleware that provides a debugging/object browser panel injected into your application.
  • express-couch-proxy — CouchDB reverse proxy middleware for Express
  • express-twitter — Twitter-specific OAuth support
  • googleclientlogin — Log in to Google services using CllientLogin method
  • http-auth — Node.js package for HTTP basic and digest access authentication.
    • htdigest — Node.js package for HTTP Digest Authentication password file utility.
    • htpasswd — Node.js package for HTTP Basic Authentication password file utility.
  • http-auth2 — HTTP basic authentication that supports multiple logins.
  • http-proxy-selective — Proxy server replace some remote static files with local ones
  • middler — A middleware runner which can itself function as middleware, with routing
  • node-evented — Extended EventEmitter
  • node-file-cache - Very small file cache for node.js http server.
  • node-force-domain — Force multiple domains to redirect (301) to a default one in your Express project.
  • Node-Http-Rewrite-Proxy — This module proxies and rewrites HTTP requests of all types. For this you can, if you want, use regular expressions.
  • node-reverse-proxy — A reverse proxy which forwards incoming HTTP requests to multiple back-end HTTP servers based upon HTTP Host header.
  • node-varnish — Connector for the Varnish cache telnet management protocol
  • notp — NodeJS One Time Password authentication, compatible with Google Authenticator
  • onion — Simple and flexible middleware stack that enables you to add a middleware layer to just about anything
  • protobuf_for_node — In-process JS-to-C++ communication using protocol buffer services
    • protobuf — A fork of protobuf_for_node with an npm package.
  • proxy-tamper — A proxy server that allows for the tampering of requests and responses.
  • socket-logger — JSON-parsable logs for Socket.IO that can push log messages to a client over Socket.IO.
  • subproxy - subdomain proxy (for example to proxy www.google.com with www.google.com.localhost)
  • proxima - HTTP/TLS(HTTPS) reverse proxy forwards incoming requests to upstream servers based on Host header or SNI host hint.
  • express-cors - Simple middleware for adding CORS functionality to your expressjs app.

本文来自互联网用户投稿,该文观点仅代表作者本人,不代表本站立场。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如若转载,请注明出处:http://www.mzph.cn/news/249165.shtml

如若内容造成侵权/违法违规/事实不符,请联系多彩编程网进行投诉反馈email:809451989@qq.com,一经查实,立即删除!

相关文章

windows server 2012 流媒体服务器搭建(直播与点播)

IIS Live Smooth Streaming(实时平滑流式处理)是微软下一代流媒体解决方案。该技术是在IIS web中集成媒体传输平台IIS media services,实现利用标准 HTTP Web 技术以及高级 Silverlight 功能,确保在互联上传输质量最佳、播放流畅音…

团队项目第一篇——NABCD

团队名称:筑梦之舟 团队项目名称:跑跑 N(Need)需求: 有许多人在跑步时想了解自己的移动轨迹和跑步距离很不便利,无法了解跑步的日程,我们的软件就是为了更加方便热爱跑步的人能够参加到跑步之中…

Vue warn Failed to mount component: template or render function not defined

问题如图,造成这类的问题一般有这么几个原因。 代码的拼写问题,当然这是最低级的错误vue定义的问题,这里我说明两点 在组件内部定义组件时,template 对应的必须是html字符串引用外部组件时,vue文件必须以template标签…

Python实现线性回归2,梯度下降算法

接上篇 4.梯度下降算法 《斯坦福大学公开课 :机器学习课程》吴恩达讲解第二课时,是直接从梯度下降开始讲解,最后采用向量和矩阵的方式推导了解析解,国内很多培训视频是先讲解析解后讲梯度下降,个人认为梯度下降算法更为…

在centos和redhat上安装docker

前置条件 64-bit 系统kernel 3.101.检查内核版本,返回的值大于3.10即可。$ uname -r 2.使用 sudo 或 root 权限的用户登入终端。 3.卸载旧版本(如果安装过旧版本的话) $ yum remove docker \docker-common \docker-selinux \docker-engine 4.安装需要的软件包 #yum-…

mac 下用 brew 安装mongodb

mac 下安装mongoDB一般俩种方法. (1)下载源码,解压,编译,配置,启动 比较艰难的一种模式. (2)brew install mongodb ,然后就可以悠闲的品一口茶,顺便瞄一眼网易新闻,这是一种傻瓜模式. 但傻瓜模式也有人为干预的时候,粗略说一下使用brew 安装mongodb 1 zhangzhimoke:~/code$…

比较python类的两个instance(对象) 是否相等

http://www.yihaomen.com/article/python/281.htm 比较python类的两个instance(对象) 是否相等 作者:轻舞肥羊 日期:2012-10-25 字体大小: 小 中 大对于同一个Class,可以创建不同的实例(instance), 如何比较这两个 instance 是否相等呢?我们知道,对于计算…

Mybaits插入记录返回主键值

某些情况进行insert时不知道主键值(主键为自增),例如系统新增用户时,有用户序号(主键 自增),用户名,密码。插入时只需插入用户名和密码,之后取得mysql自增的序号。 如下为…

Mac 解决brew一直卡在Updating Homebrew

运行命令brew install node,结果界面一直卡在Updating Homebrew...上,有两种解决办法 方法一:直接关闭brew每次执行命令时的自动更新(推荐) vim ~/.bash_profile# 新增一行 export HOMEBREW_NO_AUTO_UPDATEtrue方法二…

CAS单点登录原理简单介绍

1. SSO简介 1.1 单点登录定义 单点登录(Single sign on),英文名称缩写SSO,SSO的意思就是在多系统的环境中,登录单方系统,就可以在不用再次登录的情况下访问相关受信任的系统。也就是说只要登录一次单体系统就可以。计划在项目中加…

前端跨域通信的几种方式

前言 前端通信类的问题,主要包括以下内容: 1、什么是同源策略及限制 同源策略是一个概念,就一句话。有什么限制,就三句话。能说出来即可。 2、前后端如何通信 如果你不准备,估计也就只能说出ajax。 3、如何创建Aja…

T4((Text Template Transformation Toolkit))模版引擎之基础入门 C#中文本模板(.tt)的应用...

1 关于C#中文本模板(.tt)的简单应用https://blog.csdn.net/zunguitiancheng/article/details/78011145 任何一个傻瓜都能写出计算机能理解的程序,而优秀的程序员却能写出别人能读得懂的程序。—— Martin Fowler 2 T4模版引擎之生成数据库实体类 http://www.cnblogs…

LeetCode412Fizz Buzz

写一个程序,输出从 1 到 n 数字的字符串表示。 1. 如果 n 是3的倍数,输出“Fizz”; 2. 如果 n 是5的倍数,输出“Buzz”; 3.如果 n 同时是3和5的倍数,输出 “FizzBuzz”。 示例: n 15, 返回: [ …

vue+node实现中间层同步调用接口

为了应对业务的复杂性,提高前端的渲染能力,故在项目中引入nodejs做中间层,前端承接vue,后端对接Java。 至于为什么这么搞,网上有好多文章都在讨论,可以说仁者见仁智者见智,这里我们不在深究。 …

ES6学习笔记(二十二)ArrayBuffer

ArrayBuffer ArrayBuffer对象、TypedArray视图和DataView视图是 JavaScript 操作二进制数据的一个接口。它们都是以数组的语法处理二进制数据,所以统称为二进制数组。 二进制数组由三类对象组成。 (1)ArrayBuffer对象: 代表内存之…

如何正确地使用Java的@deprecated标注

没有什么事情比看到一个没有任何说明的deprecated标注更让人愤怒的事情了。这种做法只能让人困惑,我到底还要不要用这个已经‘废弃’的方法?如果开发者不希望某个方法再被人用的话,就要好好地为deprecated标注写说明。这篇文章就讨论了正确地…

实现div里的img图片水平垂直居中

body结构 <body><div><img src"1.jpg" alt"haha"></div> </body>方法一&#xff1a; 将display设置成table-cell&#xff0c;然后水平居中设置text-align为center&#xff0c;垂直居中设置vertical-align为middle。 <…

[ 懒人神器 ] —— OO一键build:.zip - .jar

懒人神器 更新 大家注意一下&#xff0c;由于在写入MANIFEST的时候&#xff0c;Class-Path路径给的是 ../lib &#xff0c;即上级目录的lib。 所以在对拍时如果手动移动了 jar包的位置&#xff0c;需要保证 lib/ 文件夹在存放jar包的上一级目录下&#xff0c;否则在运行时会报错…

实现Datagrid分页

Html页面&#xff1a; <!DOCTYPE html> <html> <head><meta http-equiv"Content-Type" content"text/html; charsetutf-8" /><title></title><meta charset"utf-8" /><!-- 引入相关CSS --><…

Luogu 3698 [CQOI2017]小Q的棋盘

BZOJ 4813 虽然数据范围很迷人&#xff0c;但是想树形$dp$没有前途。 先发现一个事情&#xff0c;就是我们可以先选择一条链&#xff0c;最后要走到这一条链上不回来&#xff0c;走到链上的点每一个只需要一步&#xff0c;而如果要走这条链之外的点&#xff0c;一个点需要走两步…