Skip to content

Instantly share code, notes, and snippets.

@rklancer
Created May 8, 2012 15:42
Show Gist options
  • Save rklancer/2636467 to your computer and use it in GitHub Desktop.
Save rklancer/2636467 to your computer and use it in GitHub Desktop.
Create under model-configs database
{
"_id": "_design/app",
"updates": {
"bump": "function(doc, req) { doc.value = doc.value + 1; return [doc, ''+doc.value]; }"
}
}
{
"_id": "counter",
"value": 0
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment