As far as I know there are these;

  • Camel case = coolFileName
  • Snake case = cool_file_name
  • Kebab case = cool-file-name
  • Pascal case = CoolFileName
  • Dot notation = cool.file.name
  • Flat case = coolfilename
  • Screaming case = COOLFILENAME

Personally I prefer the kebab/dot conventions simply because they allow for easy “navigation” with (ctrl+arrow keys) between each part. What are your preferences when it comes to this? Did I miss any schemes?

  • unknowing8343@discuss.tchncs.de
    link
    fedilink
    arrow-up
    19
    ·
    4 months ago

    I am a fan of Python’s or Rust’s official conventions.

    For package names, tho, I don’t get why this-is-used over this_clearly_better_system, as I would expect a double click to select_the_whole_thing, whereas it does-not-happen-here.

    • Sips'@slrpnk.netOP
      link
      fedilink
      arrow-up
      4
      ·
      4 months ago

      While i do agree, snake looks a lot better too. I just wish it was possible to navigate through each parts of the word more easily with ctrl+arrow. That would make it the superiour choice imo.