<!-- mobian-agent-page publisher="dailydev" canonical="https://daily.dev/sources/towardsdev/best-of/2021/12" -->

---
title: Best Towards Dev posts — December 2021 | daily.dev
description: The most upvoted Towards Dev posts from December 2021, curated by the daily.dev community.
canonical: https://daily.dev/sources/towardsdev/best-of/2021/12
twitter:card: summary_large_image
twitter:site: @dailydotdev
og:url: https://daily.dev/sources/towardsdev/best-of/2021/12
og:type: website
og:site_name: daily.dev
og:title: Best Towards Dev posts — December 2021 | daily.dev
og:description: The most upvoted Towards Dev posts from December 2021, curated by the daily.dev community.
og:image: https://media.daily.dev/image/upload/s--VAY5ToZt--/f_auto/v1724209435/public/daily.dev%20-%20open%20graph
---

# Best of Towards Dev — December 2021

1. 1  
[](https://daily.dev/posts/git-commands-you-must-know-xabcrjuwd "Git commands you must know")  
Article  
![Avatar of towardsdev](https://media.daily.dev/image/upload/t_logo,f_auto/v1/logos/2c710db2750a4a70835862534cb7c9d4)Towards Dev · 5y  
Git commands you must know  
Git is a very important tool for any developer. Here is a rundown of 13 important git commands to better manage your workflow. There are many more commands available that you can find here, but these are the most useful and frequently used ones and they will definitely speed up your coding process.  
141  
11
2. 2  
[](https://daily.dev/posts/refactoring-nested-loops-in-js-6o5fot3d9 "Refactoring Nested Loops In JS")  
Article  
![Avatar of towardsdev](https://media.daily.dev/image/upload/t_logo,f_auto/v1/logos/2c710db2750a4a70835862534cb7c9d4)Towards Dev · 5y  
Refactoring Nested Loops In JS  
Most of the code in JS gets nested because of the various conditions one has to handle for the solution. Ternary operator is the best and most common way to replace your “if…else” statements. Switch case statement is not the best possible way to. replace nested ‘if-else’ statements but these can be used to reduce. duplicate code which is another common mistake ignored by developers.  
124  
4
3. 3  
[](https://daily.dev/posts/javascript-the-hard-parts-part-1-o2zwaxvxt "JavaScript The Hard Parts — Part 1")  
Article  
![Avatar of towardsdev](https://media.daily.dev/image/upload/t_logo,f_auto/v1/logos/2c710db2750a4a70835862534cb7c9d4)Towards Dev · 5y  
JavaScript The Hard Parts — Part 1  
The code that you write in JavaScript is wrapped with a big thing called execution context. When we called argument, we mean the actual number or value that gets passed in, and the parameter is the placeholder that awaits it. After the function finishes or returns a value, the execution context will be deleted.  
33
4. 4  
[](https://daily.dev/posts/a-practical-guide-into-devops-as-a-back-end-engineer-4phmqapus "A practical guide into DevOps as a back-end engineer")  
Article  
![Avatar of towardsdev](https://media.daily.dev/image/upload/t_logo,f_auto/v1/logos/2c710db2750a4a70835862534cb7c9d4)Towards Dev · 5y  
A practical guide into DevOps as a back-end engineer  
How to set up a digital ocean droplet, a GCP instance, or an AWS EC2 instance. Decide which cloud platform you will use then select the link for a walk-through on how to get started. Use docker-compose to build, deploy, run, update, and stop containers using simple commands.  
27
5. 5  
[](https://daily.dev/posts/react-useeffect-cleanups-avegrqdht "React & useEffect cleanups")  
Article  
![Avatar of towardsdev](https://media.daily.dev/image/upload/t_logo,f_auto/v1/logos/2c710db2750a4a70835862534cb7c9d4)Towards Dev · 5y  
React & useEffect cleanups  
React & useEffect cleanups Tasos Kakouris 18 hours ago · 5 min read Image from https://undraw.co I hope you will enjoy this article! If you do, you can follow me on social media where I post more content like this one; check here: https://tasoskakour.com.  
22  
1
6. 6  
[](https://daily.dev/posts/gui-applications-in-a-docker-container-kgn3y-a-t "GUI Applications in a Docker Container")  
Article  
![Avatar of towardsdev](https://media.daily.dev/image/upload/t_logo,f_auto/v1/logos/2c710db2750a4a70835862534cb7c9d4)Towards Dev · 5y  
GUI Applications in a Docker Container  
The X11 socket is a program that allows users to run GUI applications on top of their OS. To launch a container we need its image file (i.e. setup) We can get the image of a container either from the internet or we can create it by ourselves.  
19  
1
7. 7  
[](https://daily.dev/posts/how-to-get-rid-of-the-last-any-in-your-typescript-code-rz-f-qfr8 "How to get rid of the last any in your TypeScript Code")  
Article  
![Avatar of towardsdev](https://media.daily.dev/image/upload/t_logo,f_auto/v1/logos/2c710db2750a4a70835862534cb7c9d4)Towards Dev · 5y  
How to get rid of the last any in your TypeScript Code  
TypeScript offers an impressive set of tools to manipulate types. Using these tools we can tighten the safety net of strong types and catch any syntax error during compilation. But there are some functions which are hard to type strongly. How to get rid of the last any in your TypeScript Code.  
17
8. 8  
[](https://daily.dev/posts/the-power-of-sql-exvosniuw "The Power of SQL")  
Article  
![Avatar of towardsdev](https://media.daily.dev/image/upload/t_logo,f_auto/v1/logos/2c710db2750a4a70835862534cb7c9d4)Towards Dev · 5y  
The Power of SQL  
Structured Query Language or SQL was created by Edgard Codd in 1970 at IBM in order to deal with the large amounts of data that was coming to the world on a regular basis. It has been over 50 years since SQL has come to be and yet it still one of the most widely utilized programming languages today. A recent analysis from dataquest.io showed that out of 32,000 jobs that mention the key word ‘data’ in it, SQL is one of. the top programming languages to have as a skill set when applying to jobs.  
10

[See all Towards Dev archives](/sources/towardsdev/best-of)

```json
{"@context":"https://schema.org","@graph":[{"@type":"Organization","@id":"https://daily.dev/#organization","name":"daily.dev","url":"https://daily.dev","logo":{"@type":"ImageObject","url":"https://daily.dev/apple-touch-icon.png","width":180,"height":180},"sameAs":["https://twitter.com/dailydotdev","https://github.com/dailydotdev","https://www.linkedin.com/company/daily-dev-ltd"]},{"@type":"WebSite","@id":"https://daily.dev/#website","url":"https://daily.dev","name":"daily.dev","publisher":{"@id":"https://daily.dev/#organization"},"potentialAction":{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https://daily.dev/search?q={search_term_string}"},"query-input":"required name=search_term_string"}}]}
{"@context":"https://schema.org","@graph":[{"@type":"CollectionPage","@id":"https://daily.dev/sources/towardsdev/best-of/2021/12#page","url":"https://daily.dev/sources/towardsdev/best-of/2021/12","name":"Best Towards Dev Posts — December 2021","description":"The most upvoted Towards Dev posts from December 2021, curated by the daily.dev community.","isPartOf":{"@type":"WebSite","url":"https://daily.dev"}},{"@type":"ItemList","@id":"https://daily.dev/sources/towardsdev/best-of/2021/12#items","numberOfItems":8,"itemListElement":[{"@type":"ListItem","position":1,"url":"https://daily.dev/posts/git-commands-you-must-know-xabcrjuwd","name":"Git commands you must know"},{"@type":"ListItem","position":2,"url":"https://daily.dev/posts/refactoring-nested-loops-in-js-6o5fot3d9","name":"Refactoring Nested Loops In JS"},{"@type":"ListItem","position":3,"url":"https://daily.dev/posts/javascript-the-hard-parts-part-1-o2zwaxvxt","name":"JavaScript The Hard Parts — Part 1"},{"@type":"ListItem","position":4,"url":"https://daily.dev/posts/a-practical-guide-into-devops-as-a-back-end-engineer-4phmqapus","name":"A practical guide into DevOps as a back-end engineer"},{"@type":"ListItem","position":5,"url":"https://daily.dev/posts/react-useeffect-cleanups-avegrqdht","name":"React & useEffect cleanups"},{"@type":"ListItem","position":6,"url":"https://daily.dev/posts/gui-applications-in-a-docker-container-kgn3y-a-t","name":"GUI Applications in a Docker Container"},{"@type":"ListItem","position":7,"url":"https://daily.dev/posts/how-to-get-rid-of-the-last-any-in-your-typescript-code-rz-f-qfr8","name":"How to get rid of the last any in your TypeScript Code"},{"@type":"ListItem","position":8,"url":"https://daily.dev/posts/the-power-of-sql-exvosniuw","name":"The Power of SQL"}]},{"@type":"BreadcrumbList","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https://daily.dev"},{"@type":"ListItem","position":2,"name":"Sources","item":"https://daily.dev/sources"},{"@type":"ListItem","position":3,"name":"Towards Dev","item":"https://daily.dev/sources/towardsdev"},{"@type":"ListItem","position":4,"name":"Best of","item":"https://daily.dev/sources/towardsdev/best-of"},{"@type":"ListItem","position":5,"name":"December 2021"}]}]}
```

