Lesson Wednesday

We'll keep adding to this list in the coming weeks, but here are the naming conventions we've learned so far:

  • Variables: use lower_snake_case when naming all variables. For example, hockey_game.
  • Functions: use lowerCamelCase when naming functions. For example, playHockeyGame.
  • Class names: use UpperCamelCase when naming classes. For example, HockeyGame.
  • Class file names: use UpperCamelCase when naming class files. For example, HockeyGame.php.
  • Twig views: use lower_snake_case.html.twig. For example, index.html.twig.
  • Silex folders: use lower_snake_case. For example, app or web or tests.