cssinjs / aphrodite-jss

Aphrodite-like API on top of JSS.
MIT License
92 stars 17 forks source link

Fix isomorphic rendering for JSS 7. #12

Closed phyllisstein closed 7 years ago

phyllisstein commented 7 years ago

This PR bumps the built-in JSS dependency to 7.1.1 and updates the reset function to use the new version's API. This unbreaks server-side rendering for the most part, though the <style> tags being rendered into the DOM are still empty both on the server and in the client---more investigation is necessary to figure out why.

kof commented 7 years ago

If they seem empty on the client only it might be the current state of the browser implementation. They don't show rules inserted using insertRule api in the dom. I fits on the server as well, something is broken here.

kof commented 7 years ago

I would prefer to find out the reason first and then merge.

phyllisstein commented 7 years ago

That seems perfectly sensible! They're empty on the server as well, so I'll see if I can figure out why.

phyllisstein commented 7 years ago

Change just pushed fixes null <style> tags on the client. They were empty on the server because I was importing a different instance of aphrodite-jss 🤕 🌴 .

kof commented 7 years ago

Just merged another PR with the update to jss 7, did it fix the issue?

kof commented 7 years ago

Seems to be fixed, please reopen if not.