Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

If you are able to "pre-render" a JavaScript app like this, then you should be serving users the pre-rendered version and then enhancing it with JavaScript after onload.

JavaScript-only apps are a blight on the web. All it takes is a bad SSL cert, or your CDN going down, and your pages become useless to the end-user.



All it takes is a bad SSL cert, or your CDN going down, and your pages become useless to the end-user.

How are non-JavaScript pages protected from this?


Apologies for being vague. Regarding the SSL certificate, I was referring to modern browsers refusing to load "unsafe" assets.

When the JS can't load, JS-heavy apps tend to either be raw templates (i.e. full of {{ statements }}) or completely blank (if the templates were going to be loaded in a separate request). As Isofarro said, non-JS pages don't suffer from this because the content is there in plain HTML.


Less dependencies, a reduced risk vector. Just the HTML page containing the content needs to load.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: