Adding content titles to urls

I have added LinksHelper class to links that point to content. All content links should now have the title of the book in the url after the id and version and before the page. For example 'contents/fff43307-25af-4c04-96fa-163449aac655@1.1/Simultaneous_Equations:2'.

There were two files where I had trouble adding LinksHelper  - src/scripts/search/results/list/item-partial.html and src/scripts/workspace/results/list/workspace-item-partial.html. These files utilize Handlebars helpers to split and limit the title in the urls.
I changed my code to use .replace() instead of split() join()

On Thu, Sep 18, 2014 at 11:02 PM, Derek Kent <notifications@github.com>
wrote:

> In src/scripts/helpers/links.coffee:
>
> >            url += "contents/#{uuid}"
> >            url += ":#{data.page}" if data.page
> > +          url += "/#{title.split(' ').join('_')}"
>
> It looks like a simple replace is about twice as fast as split/join on
> most browsers: http://jsperf.com/replace-vs-split-join-vs-replaceall
>
> —
> Reply to this email directly or view it on GitHub
> <https://github.com/Connexions/webview/pull/683/files#r17768383>.
>