DEV Community

Adam Crockett 🌀
Adam Crockett 🌀

Posted on

SHOUTING CASE - Please Stop

It's my opinion but I'm gonna say it. I'm seeing a lot of shouting case titles on dev lately.

I'm a bit of a fanatic around the meaning of case.

Lowercase can be informal and fun / unprofessional depending on your mood.

Title Case it's my favorite, I like to use this on buttons as does Apple, nice and legible.

camelCase it's for code and 🐪

PascalCase it's for classes and files containing classes but is missuse by components for some reason. I blame React and Angular class bassed for spreading this one.

snake_case belongs to php and rust amount others, I think it's the most legible in code but I am stuck with the standards of my darling language JavaScript. Curses!

SHOUTING it's so much harder to read than any other case, if try to use this to stand out i'l likely scroll past and furthermore I want to choose what to read without discrimination against other less bold cases.

I rest my case 💼

Top comments (3)

Collapse
 
adam_cyclones profile image
Adam Crockett 🌀

Absolutely fine, I do this in JavaScript (when I feel like it) but more often in Typescript.

// This isn't constant as it's just a wrapper for mutable values and does not deserve special casing.
const myObject = {}

// 100% immutably for all primitives so I would do this at the top level of any file
const RED = "red";

// In typescript enums 
enum colors {
   RED,
   BLUE
   GREEN
}
Collapse
 
adam_cyclones profile image
Adam Crockett 🌀 • Edited

PDS OWNER CALIN <<
🎉 I think I'm outnumbered