Hacker News new | ask | show | jobs
by JimDabell 157 days ago
> $() CSS parsing and DOM traversal was way slower than querySelector or getElementById, both of which predate jquery by years.

You have that backwards – jQuery predates querySelector by years.

The reason why getElementById is fast is because it’s a simple key lookup.