Yeah, it is probably not significant next to the DOM parsing itself. Just
maybe something to consider if you notice perf problems in this endpoint.


On Mon, Mar 17, 2014 at 10:49 PM, wdoug <notifications@github.com> wrote:

> In evernoteModel.js:
>
> > @@ -161,3 +163,22 @@ function logErrors(err, data, callback) {
> >          callback(data);
> >      }
> >  }
> > +
> > +// Recursively goes through child nodes and gets the values
> > +function getChildNodeValues(node) {
> > +    if (node.hasChildNodes()) {
> > +        var values = '';
> > +        for (var i = 0; i < node.childNodes.length; i += 1) {
> > +            // TODO change to context sensitive new lines
> > +            values += getChildNodeValues(node.childNodes[i]) + '\n';
>
> Thanks for the tip about appending strings creating new string instances.
> I didn't know that.
>
> Yeah, I think the performance of this could probably be increased a lot.
> For one thing, I'm not sure the DOMParser package is very fast for what I
> am doing.
>
> --
> Reply to this email directly or view it on GitHub<https://github.com/wdoug/jot/pull/21/files#r10690491>
> .
>