[OpenStack-Infra] best way to add handlebars.js to infra?

Robert Collins robertc at robertcollins.net
Mon Sep 29 22:21:38 UTC 2014


On 30 September 2014 11:12, Sean Dague <sean at dague.net> wrote:
> Over the weekend I redid elastic-recheck to use handlebars.js instead of
> inline dom building... it's so much nicer:
> https://github.com/openstack-infra/elastic-recheck/blob/master/web/share/index.html#L61-L79
> and
> https://github.com/openstack-infra/elastic-recheck/blob/master/web/share/elastic-recheck.js#L82-L85
>
> I'd really like to get this pattern into more of our tooling, as I think
> it will expand the scope of the people who can contribute, as they can
> address formatting issues outside of javascript logic.

+1. You might like https://github.com/wbond/pybars too (its a python3
updated fork of pybars, which I wrote back at Canonical). I'm not sure
if its directly relevant here or not.

> It seems like it would be nice to have it be rooted on
> static.openstack.org like jquery is, so we've got a common copy that
> everyone can use.
>
> So... questions:
>
> - Should javascript libraries be hosted on static.openstack.org (which
> reduces what users need to download) or should we carry them around in
> every app (which means static.o.o could be blocked or down, but the app
> would still work)?

For apps that are our development tooling, I think using static.o.o is
fine. For apps that we expect folk to install locally in their clouds,
they should carry them (or at least be able to carry them, as secure
environments get antsy about random 3rd-party domains having code
access to their credentials ;)).

-Rob


-- 
Robert Collins <rbtcollins at hp.com>
Distinguished Technologist
HP Converged Cloud



More information about the OpenStack-Infra mailing list