Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

173
Views
The reason to use "-" instead of "_" in the HTML class and id attributes

why do people use " - " between their words instead of " _ " for example class ="btn-submit", isn't this inefficient? if you use "_" by double-clicking it will select the whole class name instead of only one side so copying and using it in CSS or javascript will be easier. double click on each of these below to see the difference

class ="btn-submit"

class ="btn_submit"

so there is any specific reason to do it that way or it's just something that is people using by bad habit.

about 4 years ago · Juan Pablo Isaza
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!