Y
Hacker News
new
|
ask
|
show
|
jobs
by
clintonc
4010 days ago
My rationale for single quotes is also that JSON chose for you -- if you have JSON-formatted strings in your javascript and you use single quotes for your strings, you don't have to escape the double quotes.
2 comments
joepie91_
4010 days ago
I'd find it very worrying that you have JSON-formatted strings in JS code. Why would you do that, when there's also a native representation?
link
phpnode
4010 days ago
Do you do that more or less frequently than writing strings with apostrophes?
link