-
-
Notifications
You must be signed in to change notification settings - Fork 32.7k
Closed
Labels
scope: stylesSpecific to @mui/styles. Legacy package, @material-ui/styled-engine is taking over in v5.Specific to @mui/styles. Legacy package, @material-ui/styled-engine is taking over in v5.type: new featureExpand the scope of the product to solve a new problem.Expand the scope of the product to solve a new problem.
Milestone
Description
#I'm looking into new features of React 0.16; in particular the new renderToNodeStream() method.
To be able to use that, one would need to provide all the necessary CSS before any other body markup to avoid the Flash Of Unstyled Content issue.
Is it possible with your JSS implementation to utilize this? I do not want to run the renderToString() method since it is slow. I'm looking for a solution where the markup could be parsed and the styles could be calculated pre-render, and then later render the final app with renderToNodeStream().
In pseudo code:
let markup = (<MyApplication />);
let css = calculateStyles(markup);
let stream = renderToNodeStream(<MyApplication css={css} />);
// stream.pipe etc. ...I realize this might not be a material-ui specific issue, but rather related to JSS. But I'm curious if you already have thought about this for your framework.
mulyoved, mediafreakch, sergei-zelinsky, kdelmonte, Romcol and 1 more
Metadata
Metadata
Assignees
Labels
scope: stylesSpecific to @mui/styles. Legacy package, @material-ui/styled-engine is taking over in v5.Specific to @mui/styles. Legacy package, @material-ui/styled-engine is taking over in v5.type: new featureExpand the scope of the product to solve a new problem.Expand the scope of the product to solve a new problem.