I’ve always used hypens in CSS classes and IDs. I’ve noticed that many Rails plugins (and Rails core) use underscore. I was wondering is this is a convention in Rails application?
I’m confused about what convention for follow because I’m also using ZURB Foundation gem which uses hyphens.
My venture would be that since hyphens are rarely used for variable names, class names, method names etc… developers out of habit use underscores when naming in HTML and CSS.
I don’t believe there is any convention either way though. Just preference.