Little Snippets
summary
Small, concrete changes save time and reduce bugs: prefer use max not sort.last for intent and speed; use ActiveRecord queries instead of loading all records; replace regex matches with include? or predicates when only a boolean matters; avoid redundant `self`, prefer `require_relative` for sibling files; name config keys with units; prefer foreign‑key cascades over has_many without `dependent`; anchor regexes with `\A` and `\z` when matching whole strings; use `tap` and `slice` for clearer object construction; RuboCop enforces consistency.
AI-written summary · about
chapters (11)
- 0:00Introduction
- 1:52Little details in code
- 6:31Conciseness in programming
- 17:19Readability and negations
- 21:38Easy to read code
- 27:40Empathy in code
- 28:25Natural ordering
- 32:16Precision in code
- 38:16Regular expressions
- 43:17Code style importance
- 45:43Q&A and thanks








