I have a large javascript string. var s = '...............'; // this is about 32000 characters long.
if you wonder: that bit of javascript is autogenerated.
Does anybody know if it is better to store it outside of the javascript For instance in a dom object in the html page and then retrieve it (e.g. var s = document.getElementById('hiddenTextArea').value; ) or is it okay to leave it in the javascript ?
note: I am not interested in the cost occurred in downloading the large string. The question is really if it is okay to store a large string inside the javascript or not and whether there are better ways
Many Thanks