Closed Bug 899165 Opened 11 years ago Closed 11 years ago

Move UI Loading in Dom Fragments to be done with Nunjucks

Categories

(Webmaker Graveyard :: Popcorn Maker, defect)

x86
macOS
defect
Not set
normal

Tracking

(Not tracked)

RESOLVED WONTFIX

People

(Reporter: mjschranz, Assigned: mjschranz)

Details

As it stands right now dealing with localization in Popcorn Maker is going to be a colossal PITA.

We don't load any of our UI elements with any sort of rendering engine. It's all done through DOM fragments and throwing them into the DOM.

This is a two parter. First, we need to just make the main UI elements load through the initial template render server side. This includes:

- Header Area
- Editor Area
- Timeline Area

This means any strings in here can easily be translated server side no problem. It also means we probably will gain some benefits to our initial and potential make it feel less "janky". We aren't supporting multiple templates anymore so the idea of having butter load all of the UI elements seems not needed.

The second part is converting the loading of individual layout bits to use nunjucks client side. Webmaker.org already does this with loading some of the gallery makes on certain pages. I want to use this in a couple of places in PM, most notably:

- Loading in individual editors (IE, You selected a text trackevent and now we are loading the text editor).

Actually, I think most of the client side uses will be just with our editor system but if there's some I'm missing we can add to this.

Anyway, thoughts? This ticket should be a META tracking ticket and I'll file individual tickets assigned to me later but I would rather get discussion first.
Question: why not have our domFragments actually come from URLs which are routes that do the translation/rendering server side?

Also, I think the stuff in bug 896623 will help a lot with this.
Depends on: 896623
Hmm, that an interesting thought. I'm not sure it would work completely for things like our editors for example. Currently we store their layout as domFragments and load them in on demand after we have used say require.

I like the idea of keeping things like our header/timeline/editor area as nunjucks layouts server side and we have an endpoint that renders that HTML on the server, serves up to use and then we put it in the DOM like that. Might spend sometime playing with that for the rest of this week.
No longer depends on: 896623
We went with a different direction.
Status: ASSIGNED → RESOLVED
Closed: 11 years ago
Resolution: --- → WONTFIX
You need to log in before you can comment on or make changes to this bug.