# connect-backbone-router

> Creates routes for interacting with Backbone from Connect/Express

Latest version **0.0.4** (published 2012-07-31) · MIT license · 0 weekly downloads

## Install

```sh
npm install connect-backbone-router
pnpm add connect-backbone-router
yarn add connect-backbone-router
bun add connect-backbone-router
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support; pre 1.0.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.0.4 |
| Published | 2012-07-31 |
| First published | 2012-06-07 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Node | * |
| Dependencies | 0 |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 9 |
| Author | Morgan 'ARR!' Allen |
| Maintainers | morganrallen |
| Keywords | connect, express, backbone, server |

## Links

- npm: https://www.npmjs.com/package/connect-backbone-router
- Repository: https://github.com/morganrallen/connect-backbone-router
- npm.io page: https://npm.io/package/connect-backbone-router

## Recent versions

- 0.0.4 (latest) — 2012-07-31
- 0.0.2 — 2012-06-07
- 0.0.1 — 2012-06-07

## README

connect-backbone-router
=======================
Sets routes for Backbone collections in Connect

[![Build Status](https://secure.travis-ci.org/morganrallen/connect-backbone-router.png)](http://travis-ci.org/morganrallen/connect-backbone-router)


Example
=======

```javascript
var Backbone = require("Backbone"),
	connect = require("connect"),
	color = require("colors"),
	connect_backbone_router = require("./../"),
	
	request = require("request");

var app = connect();

var collections = {
	hitchhikers: new Backbone.Collection([
		new Backbone.Model({
			id: 0,
			name: "Zaphod"
		})
	])
};

app.use(connect.logger());
app.use(connect.bodyParser());

app.use(connect_backbone_router({
	debug: true,
	path: "/data",
	collections: collections
}));

app.use(function(req,res,next) {
	res.end("That's all folks!");
});

var server = app.listen(8080);
```

Now you should be able to get the whole collection at http://localhost:8080/data/hitchhikers

The single model at http://localhost:8080/data/hitchhikers/0

Or an attribute at http://localhost:8080/data/hitchhikers/0/name

---
_Source: https://npm.io/package/connect-backbone-router · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
