Closed k4mr4n closed 6 years ago
This seems like a duplicate of https://github.com/airbnb/hypernova/issues/115
@ljharb yes no one there answered and I thought its concern with this repo too so I clone it here! and what do you think about it?
@ljharb I fixed it with if-else in my code that's why I closed it and in the first place my if-else had a syntax problem that's why I was getting TypeError 😞
Thanks for clarifying :-)
My apologies for resurrecting the dead but why would someone have to manually check whether the server failed to render or not..?
reactRender should have been able to figure that out from the data keys... right?
Hey all
If hypernova server fails by any reason and the html content would be empty, then the
renderReact('Component', Component)
wouldn't work either returns blank page and I have to call:In this case how could I know my root is empty? because this condition throws error due to undefined document object:
document.getElementById('root') !== null && document.getElementById('root').hasChildNodes()