couchdb-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Aurélien Bénel <>
Subject Re: rewrites.js: Format for non-empty `query`
Date Tue, 17 Jan 2017 16:53:18 GMT
Hi folks,

> Has anyone explored the (relatively) new ‘Rewrite using JS’ feature?

No-one? Really?

> The problem is that, for now, I fail figuring out how to format the value of the `query`
attribute. (…) 
> Then I reread the corresponding documentation (
> and discovered that `query`was supposed to be an array. But nothing was written about
how the array was supposed to be formatted.

I’ve just found the acceptance tests corresponding to this feature:

So, it seems that the documentation is erroneous: the `query` attribute not an array but an
That makes more sense!

I would still be interested in `rewrites.js` samples. But if anyone have any I will « guess
and check » starting from the examples given in the tests.


View raw message