This video is packed with information on how Facebook uses of CSS-in-JS, code splitting, GraphQL ability to require code... I highly recommend watching if you're interested in the space.https://developers.facebook.com/videos/2019/building-the-new-facebookcom-with-react-graphql-and-relay/ …
-
-
Replying to @Vjeux
See, I wasn’t sure if the solution was still CSS-in-JS or not judging from the video. I observed that atomic CSS classes were created, but got no indicator of how they were created or used within the system. I suppose that means
huh?1 reply 0 retweets 1 like -
They’re authored in JS then statically compiled to atomic CSS.
1 reply 0 retweets 15 likes -
Replying to @sophiebits @Vjeux
Ah okay. I knew that was the case before but wasn’t sure if something had changed
1 reply 0 retweets 1 like -
From what you remember, it’s likely mostly the same. Although
@naman34 has been working on some awesome changes recently that will be the final solution that we talk about publicly.1 reply 0 retweets 10 likes -
Does that imply that you are going to open source your solution?
1 reply 0 retweets 0 likes -
-
I meant, are you going to open source it? :D
I've been working on what seems a similar solution but I'd rather not reinvent the wheel and wait for a stable one battle tested at your scale1 reply 0 retweets 0 likes -
Replying to @giuseppegurgone @MarkFunk and
Oh I meant, no idea. It’s bound to a Babel-implementation, and still has areas of improvement. It’s hard because as soon as FB open sources a CSS-in-JS solution then Readt devs will flock to it. Important that it’s done right, but not sure what that means yet.
1 reply 0 retweets 4 likes -
> a Babel-implementation do you mean a fork of Babel or a Babel plugin to hoist/extract to static? > It’s hard because as soon as FB open sources a CSS-in-JS solution then React devs will flock to it Good point! Maybe a detailed technical write-up (tease) would be enough
1 reply 0 retweets 0 likes
There’s a Babel plugin that does all the processing and returns code that looks like: StyleSheet.inject(‘CSS HERE’); That’s done in prod and dev. In production though the extraction is as easy as taking the CSS and removing it from the JS.
Loading seems to be taking a while.
Twitter may be over capacity or experiencing a momentary hiccup. Try again or visit Twitter Status for more information.
he/him 
