

Ask HN: How do you quote? - alecbenzer

In contexts where it doesn't matter what kind of quotes (' vs ") you use, which do you use for strings? Singles seem "cleaner" in some cases but I tend to carry over doubles from use in other languages.
======
AndrewGCook
Single quotes as much as possible, unless it's a MySQL call or HTML.

I hack in PHP mostly.

------
kragniz
I always use single quotes if I can, one less keypress. I'm a Pythonist.

------
parthshah
I personally prefer single quotes. There are some advantages of double quotes
like you don't have to close quotes every time you use variable. But I prefer
singles because its cleaner and it helps me read my own code better.

