GithubHelp home page GithubHelp logo

pouchdb-list's Introduction

pouchdb-list

Build Status Dependency Status devDependency Status

A PouchDB plug-in that allows you to re-use your CouchDB list functions on the client side. A browser version is available.

TODO: integrate, update & make nice:

.. _pouchdb-list-plug-in:

PouchDB List plug-in
====================
+----------------------+-----------------+
| NodeJS package name: | `pouchdb-list`_ |
+----------------------+-----------------+
| Browser object name: | ``window.List`` |
+----------------------+-----------------+

First, make sure you understand how list functions work in CouchDB. A
good start is `the CouchDB guide entry on lists`_.

.. _pouchdb-list: https://www.npmjs.org/package/pouchdb-list
.. _the CouchDB guide entry on lists: http://guide.couchdb.org/draft/transforming.html

.. js:function:: List.list(listPath[, options[, callback]])

   Runs a list function on a view. Both are specified via the
   ``listPath`` parameter.

   :param string listPath: a url of the form
       ``"designDocName/listFuncName/viewName"``
   :param object options: this object is supplemented with defaults
       until a complete `CouchDB request object`_ has been formed, which
       is then passed into the list function.
   :returns: When succesful, the list function's result in the form of a
       `CouchDB response object`_. Otherwise, an error object with one
       of the following statuses: 400, 404, 406 or 500.

.. _CouchDB request object: http://docs.couchdb.org/en/latest/json-structure.html#request-object
.. _CouchDB response object: http://docs.couchdb.org/en/latest/json-structure.html#response-object

pouchdb-list's People

Contributors

greenkeeperio-bot avatar marten-de-vries avatar mroeder avatar

Stargazers

 avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

pouchdb-list's Issues

Get test coverage up to 100%, even without external modules

Test coverage isn't completely at 100% (just run npm test). The code paths were previously probably covered by other packages (I suspect pouchdb-rewrite), but it's best if some dedicated tests were written. Running the test suites of other modules alongside own tests probably adds too much complexity to be worth it in this case.

include_docs seems not work

using a list function with include_docs=true will return the document in
row.doc after row=getRow()
Which does not work in this plugin.
It also not set a row.value

this still works?

witch version of pouch work this?
i got an error:

Uncaught (in promise) TypeError: db.getUrl is not a function

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.