NoAlias
NoAlias

Reputation: 9193

Is there a Benefit to Having the Name of Javascript Functions Start with Lowercase Letters?

I have noticed that most Javascript methods (framework and custom) start with lowercase letters. Is there a reason and/or benefit to this?

Upvotes: 1

Views: 266

Answers (2)

Gabe Moothart
Gabe Moothart

Reputation: 32082

In any case-sensitive language, it's especially important to be consistent about how you case variables. But starting with lower-vs-upper is just an idiom that's evolved in the community.

Upvotes: 0

Paul Roub
Paul Roub

Reputation: 36438

There's no technical reason. It's about readability, tradition, similarity to existing code. Consistency leads to readability, and arbitrary divergence stands out for no good reason.

Upvotes: 1

Related Questions