pouchdb-update
Advanced tools
Comparing version 1.0.7 to 1.0.8
{ | ||
"name": "pouchdb-update", | ||
"version": "1.0.7", | ||
"main": "index.js", | ||
"description": "A PouchDB plug-in that allows you to re-use your CouchDB update functions on the client side.", | ||
"repository": "pouchdb/pouchdb-update", | ||
"homepage": "http://python-pouchdb.marten-de-vries.nl/plugins.html", | ||
"keywords": [ | ||
"pouch", | ||
"pouchdb", | ||
"couch", | ||
"couchdb", | ||
"update", | ||
"design", | ||
"handler" | ||
], | ||
"license": "Apache-2.0", | ||
"author": "Marten de Vries", | ||
"dependencies": { | ||
"couchdb-objects": "^1.0.0", | ||
"couchdb-eval": "^1.0.0", | ||
"promise-nodify": "^1.0.0", | ||
"pouchdb-req-http-query": "^1.0.0", | ||
"couchdb-resp-completer": "^1.0.0", | ||
"pouchdb-promise": "^0.0.0", | ||
"pouchdb-plugin-error": "^1.0.0" | ||
}, | ||
"devDependencies": { | ||
"browserify": "^4.1.8", | ||
"uglify-js": "^2.4.13", | ||
"es3ify": "^0.1.3" | ||
}, | ||
"scripts": { | ||
"build-js": "mkdir -p dist && browserify index.js -s Update -g es3ify -o dist/pouchdb-update.js", | ||
"build": "npm run build-js; cd dist; uglifyjs pouchdb-update.js -mc > pouchdb-update.min.js" | ||
} | ||
"name": "pouchdb-update", | ||
"version": "1.0.8", | ||
"main": "index.js", | ||
"description": "A PouchDB plug-in that allows you to re-use your CouchDB update functions on the client side.", | ||
"repository": { | ||
"type": "git", | ||
"url": "https://github.com/pouchdb/pouchdb-update.git" | ||
}, | ||
"keywords": [ | ||
"pouch", | ||
"pouchdb", | ||
"couch", | ||
"couchdb", | ||
"update", | ||
"design", | ||
"handler" | ||
], | ||
"license": "Apache-2.0", | ||
"author": "Marten de Vries", | ||
"dependencies": { | ||
"couchdb-objects": "^1.0.0", | ||
"couchdb-eval": "^1.0.0", | ||
"promise-nodify": "^1.0.0", | ||
"pouchdb-req-http-query": "^1.0.3", | ||
"couchdb-resp-completer": "^1.0.0", | ||
"pouchdb-promise": "^0.0.0", | ||
"pouchdb-plugin-error": "^1.0.0" | ||
}, | ||
"devDependencies": { | ||
"pouchdb-plugin-helper": "^2.0.0" | ||
}, | ||
"scripts": { | ||
"helper": "./node_modules/.bin/pouchdb-plugin-helper", | ||
"test": "npm run helper -- test", | ||
"build": "npm run helper -- build Update" | ||
} | ||
} |
pouchdb-update | ||
============== | ||
[![Build Status](https://travis-ci.org/pouchdb/pouchdb-update.svg?branch=master)](https://travis-ci.org/pouchdb/pouchdb-update) | ||
[![Dependency Status](https://david-dm.org/pouchdb/pouchdb-update.svg)](https://david-dm.org/pouchdb/pouchdb-update) | ||
[![devDependency Status](https://david-dm.org/pouchdb/pouchdb-update/dev-status.svg)](https://david-dm.org/pouchdb/pouchdb-update#info=devDependencies) | ||
A PouchDB plug-in that allows you to re-use your CouchDB update | ||
functions on the client side. A browser version is available. | ||
See also [pouchdb-update's documentation](http://pythonhosted.org/Python-PouchDB/js-plugins.html#pouchdb-update-plug-in) | ||
TODO: convert the following to markdown + update + make nicer | ||
```rst | ||
.. _pouchdb-update-plug-in: | ||
[Website of this plug-in and a few others](http://python-pouchdb.marten-de-vries.nl/plugins.html) | ||
PouchDB Update plug-in | ||
====================== | ||
+----------------------+-------------------+ | ||
| NodeJS package name: | `pouchdb-update`_ | | ||
+----------------------+-------------------+ | ||
| Browser object name: | ``window.Update`` | | ||
+----------------------+-------------------+ | ||
First, make sure you understand how update handlers work in CouchDB. A | ||
good start is `the wiki entry on update handlers`_. | ||
.. _pouchdb-update: https://www.npmjs.org/package/pouchdb-update | ||
.. _the wiki entry on update handlers: https://wiki.apache.org/couchdb/Document_Update_Handlers | ||
.. js:function:: Update.update(updatePath[, options[, callback]]) | ||
Runs the update function specified by ``updatePath``, saving part of | ||
its result in the database and returning the other part in the form | ||
of a CouchDB response object. | ||
:param string updatePath: has the following form: | ||
``"designDocName/updateHandlerName[/docId]"``. The last being | ||
optional, like in CouchDB. | ||
:param object options: a request object stub. There's also | ||
``options.withValidation``, if true, this function saves the | ||
update handler result using the | ||
:js:func:`Validation.validatingPut` function instead of using the | ||
:js:func:`PouchDB.prototype.put` function. | ||
``` |
Sorry, the diff of this file is not supported yet
10945
1
9
226
44