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

What are the advantages of concatenating the data with the JS vs making a request? Only page load time?


You can't make a cross-domain ajax request, so all of the data needs to be included with the JS.


I had never thought of doing this. Its a great idea. How widespread is this technique?


Quite, it's mostly used as JSONP. See http://en.wikipedia.org/wiki/JSONP




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

Search: