{"name":"broker","description":"A simple node.js broker for intermodule communication.","version":"0.1.1","repository":{"type":"git","url":"git@github.com:tommedema/node-broker.git"},"author":{"name":"tmedema"},"main":"src/broker.js","directories":{"src":"src"},"engines":{"node":"*"},"_id":"broker@0.1.1","_engineSupported":true,"_npmVersion":"0.3.18","_nodeVersion":"v0.4.5","files":[""],"_defaultsLoaded":true,"dist":{"shasum":"d618fdf8ce1dade303b2d99441bed94a58685a78","tarball":"http://registry-npm.ywwl.com/broker/download/broker-0.1.1.tgz","integrity":"sha512-oUo+CCCSmZpNK9e7P57mgAFZ4AJUJS0nlPfucTFmfT3KzApzCxH2MWAvmH8pic2QugGvA+O9pOdvd6h2Zk47yQ==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQD1pM3N2YZa30KKcBy0U+qKvIvRzZWGGmDrvuerO7UjXgIhAJxZ4/pMbCdhF9yX2ZOvDvQLxwiE36lsNAvXxGoPjYdQ"}],"size":3170,"noattachment":false,"key":"/broker/-/broker-0.1.1.tgz"},"readme":"# broker\n\nExpress/Connect middleware that serves local or remote static files. \n\n## Install\n\n```\nnpm install broker --save\n```\n\n## Usage\n\nServe static files\n\n```js\nvar express = require('express');\nvar broker = require('broker');\n\nvar app = express();\n\napp.use(broker({\n  root: '/public'\n}));\n\napp.listen(3000, function () {\n\n});\n```\n\nProxy remote files\n\n```js\nvar express = require('express');\nvar broker = require('broker');\n\nvar app = express();\n\napp.use(broker({\n  root: 'http://proxyserver.com'\n}));\n\napp.listen(3000, function () {\n\n});\n```\n\n### broker([options])\n\n* **options** - the options are similar to the [send module](https://github.com/visionmedia/send#options) because it uses this to serve local static files. Here are a few:\n  * `root` - the root directory if serving local files or the url to prepend to requests to proxy remote static files\n  * `index` - a string or array of strings that define the directory index file\n  * `dotfiles` - how to handle files that begin with a dot. These are usually hidden files. The default value is ignore. Available options:\n    * `allow` - No special treatment for dotfiles\n    * `deny` - Send a 403 for any request for a dotfile\n    * `ignore` - Pretend like the dotfile does not exist and 404\n  \n\n\n\n## Run Tests\n\n```\nnpm install\nnpm test\n```\n","publish_time":1305552347492,"maintainers":[{"name":"scottcorgan","email":"scottcorgan@gmail.com"},{"name":"mbleigh","email":"michael@intridea.com"}],"_cnpm_publish_time":1305552347492,"dist-tags":{"latest":"1.0.1"}}