Samantha Ming
Jan 5 Β· 5 min read

For the entire month of December, I posted DAILY code tidbits! 30 days straight of the very best JavaScript, HTML, and CSS snippets.

I posted this series on my Instagram and Twitter. Don’t worry if you missed it! Here’s the summary of all 30 Code Tidbits. Make sure you scroll to the end where I also included code notes. Enjoy! 🎁

Code Notes

2 Methods to Convert to true Array

ES6: Shorthand for Defining Methods in Objects

ES6: Creating Objects with Dynamic Keys

Remove Array Duplicates using ES6 Set

Split String using ES6 Spread

Use console.table instead to display your data

Combine Multiple Arrays using ES6 Spread

CSS Custom Selection Styling

Named Parameters using ES6 Destructured Objects

Setting Default Parameters

JS Essentials: Falsy Values

Refactoring the if condition

Checking if String contains Substring

How to Compare 2 Objects in JavaScript

Better Boolean Variable Names

Bad Variable Names to Avoid

ES6 Way to Clone an Array

Make a HTML element editable with contenteditable

Dynamic Property Name with ES6

No Else Return

No Useless Escape

CSS Caret Color

Colorful Console Message

Refactor if-else with Ternary Operator (No code notes)

String toUpperCase()(No code notes)

while loop (No code notes)

Create a Downloadable Link using HTML5 Download Attribute

JavaScript: 3 Ways to Convert to Boolean

2 Ways to Repeat Strings in JavaScript

4 Ways to Combine Strings in JavaScript

That’s a wrap! I hope you enjoyed this #CodeTidbits30 daily series that I posted on my Instagram and Twitter.

I have a lot of exciting articles and programming posts coming, so make sure you stay tuned!

Weekly Code Tidbits will return on my Instagram and Twitter. And of course, don’t forget to Follow me on Medium to get the more in-depth code notes 🍎

Thanks for reading ❀

Say Hello! Instagram | Facebook | Twitter | SamanthaMing.com | Blog


JavaScript news and opinion.

Samantha Ming

Written by

Front End Developer πŸ‘©β€πŸ’» I love learning new things and sharing them with my community. Follow me to catch my weekly code tidbits πŸ”₯



JavaScript news and opinion.

Welcome to a place where words matter. On Medium, smart voices and original ideas take center stage - with no ads in sight. Watch
Follow all the topics you care about, and we’ll deliver the best stories for you to your homepage and inbox. Explore
Get unlimited access to the best stories on Medium β€” and support writers while you’re at it. Just $5/month. Upgrade