3 ms·
Client side code can assume a single-user context. It could write user-specific values to globals, use them in modules, etc., and it would be fine on the client
by spankalee 6y ago
Client side code can assume a single-user context. It could write user-specific values to globals, use them in modules, etc., and it would be fine on the client side. But run in a multi-user environment it would be relatively easy to leak data from one user to another. SSR should run each request, or at least session, in a fresh context.
- jgalvez 6y agoThat would be the case in a typical Node setting, but in this case, each thread runs the renderer no more than once at a time. So we just have to provide a fresh state.