On Sat, Jan 10, 2009 at 1:15 PM, Chris Anderson <[email protected]> wrote:

> On Fri, Jan 9, 2009 at 2:03 PM, Dave <[email protected]>
> wrote:
> > Hi,
> >
> > I was wondering if there was a standard way to add helper functions or
> > augment the built-in data types (Array, Date, etc.) in the JavaScript
> > global object used by couch db for map/reduce functions. My motivation
> > here is to add some code for parsing ISO8601 date strings into
> > JavaScript Date objects for the purpose of view collation in multiple
> > views.
> >
>
> The preferred way to do this is to add the library code itself to your
> function. I use a script designed to push filesystem contents to
> design documents. It has an ability to inline additional JavaScript
> into your functions.
>
> I'm in the middle of extracting it to its own project, so the install
> will be getting easier, but the Ruby code is available here:
>
> http://github.com/jchris/couchapp/tree/master
>
> --
> Chris Anderson
> http://jchris.mfdz.com
>

is this related to the !json and !code macros I've seen in the sofa code? Is
what executes these macros buried in couch trunk or is it something else?

Reply via email to