in my view i have one object, and want to work with this onject from javascript
i try to
var js_obj = jQuery.parseJSON('<%=raw @rails_obj.to_json %>');
it works. but if i have “‘” symbols, new string symbols, ,,, in this object all fails.
Have somebody know good approach to do it?
JSON is valid Javascript right out of the box, so why not just do: