serlo / athene2-blue-gum

Complete rework of the current athene2 design with a focus on responsive, mobile first.
https://athene2-blue-gum.netlify.com
Apache License 2.0
4 stars 0 forks source link

Supporting multiple react root elements #50

Closed Entkenntnis closed 5 years ago

Entkenntnis commented 5 years ago

We want to replace components one-by-one, so the nextjs-server should output fragments that are compatible with each other. This can be achieved by:

Every fragment only loads resources if they are not yet loaded. Every fragment has unique divs for react and json-data. When react starts, it loads all page ids and renders them.

This is implemented in this PR.

elbotho commented 5 years ago

nice! did you find a solution to the package size / bodyParser issue?

Entkenntnis commented 5 years ago

yes, I've excluded bodyparser for the client, package size is now about 400kB with each compononent only adding about 2kb

Entkenntnis commented 5 years ago

moving this changes into serlo.org repository, so closing this PR