diff options
Diffstat (limited to 'www/content/essays/prefer-if-statements.md')
-rw-r--r-- | www/content/essays/prefer-if-statements.md | 13 |
1 files changed, 9 insertions, 4 deletions
diff --git a/www/content/essays/prefer-if-statements.md b/www/content/essays/prefer-if-statements.md index 1f62eacf..4bc60626 100644 --- a/www/content/essays/prefer-if-statements.md +++ b/www/content/essays/prefer-if-statements.md @@ -1,9 +1,14 @@ +++ title = "Prefer If Statements To Polymorphism..." +description = """\ + In this collection of tweets, Carson Gross explores unconventional programming principles, including favoring if \ + statements over polymorphism, minimizing abstractions, and prioritizing practical, implementation-driven \ + development. He challenges traditional software design norms, advocating for simplicity, locality, and utility over \ + complexity and abstraction.""" date = 2024-12-07 updated = 2024-12-07 +authors = ["Carson Gross"] [taxonomies] -author = ["Carson Gross"] tag = ["posts"] +++ @@ -21,7 +26,7 @@ tag = ["posts"] > they should just do something useful man * *[The Minimize Abstractions Principle](https://x.com/htmx_org/status/1843806270559793475)* > The Minimize Abstractions Principle (MAP) is a computer programming principle that states that "a module should - > minimize the number of abstractions it contains, both in API and in implementation. Stop navel gazing nerd. + > minimize the number of abstractions it contains, both in API and in implementation. Stop navel gazing nerd." * *[The Try It Out Substitution Principle](https://x.com/htmx_org/status/1843807054970139139)* > The "Try It Out" Substitution Principle states that you should try something out and, if that doesn't work, think about why, and substitute something else for it instead. > @@ -35,7 +40,7 @@ tag = ["posts"] > > when they exhaust that budget & ask for more, tell them they can have another abstraction when they remove an existing one > - > when they complain, look for classes with the term "Factory", "Lookup" or "Visitor" in their names] + > when they complain, look for classes with the term "Factory", "Lookup" or "Visitor" in their names * *[Fewer Functions](https://x.com/htmx_org/status/1843822378352291914)* > if your function is only called in one place, consider inlining it & reducing the total number of method signatures in your module, to help people better understand it > @@ -43,7 +48,7 @@ tag = ["posts"] * *["God" Object](https://x.com/htmx_org/status/1843823231771521367)* > consider creating "God" objects that wrap a lot of functionality up in a single package > - > consumers of your API don't want to learn 50 different classes to get something done, so give them a few that provide the core functionality of your module with minimal fuss] + > consumers of your API don't want to learn 50 different classes to get something done, so give them a few that provide the core functionality of your module with minimal fuss * *[Copy & Paste Driven Development](https://x.com/htmx_org/status/1843827082687852706)* > copy&paste driven development is a development methodology where, when you need to reuse some code but in a slightly different manner, you copy & paste the code & then modify it to satisfy the new requirements > |