Here is a collection of visual JavaScript tips and explanations that can help JavaScript developers of any skill level!

πŸ§΅πŸ‘‡πŸ»
The anatomy of a for-loop in JavaScript. πŸ‘‡πŸ»
The anatomy of a while-loop in JavaScript. πŸ‘‡πŸ»
The anatomy of a do-while-loop in JavaScript. πŸ‘‡πŸ»
The anatomy of a for-of-loop in JavaScript. πŸ‘‡πŸ»
The anatomy of Array map in JavaScript. πŸ‘‡πŸ»
This is how you can combine a Promise and setTimeout to create a cancelable delay. πŸ‘‡πŸ»
This is how you can make an argument required by using a function as a default parameter.

Whenever no argument is passed, the function fires and throws an Error that tells what went wrong. πŸ‘‡πŸ»
The Performance API is actually way better suited to measure execution times than the Date API.

Please be informed that many browsers reduce the precision to prevent fingerprinting.

It's best to use it in your tests ran with Node! πŸ‘‡πŸ»
You can unpack all nested arrays of an array by passing Infinity as an argument to Array flat.

This way, you get all individual values one after the other. πŸ‘‡πŸ»
The nullish coalescing operator is often a better choice than using the logical OR operator.

Contrary to the logical OR, the nullish coalescing operator only reacts to null and undefined. πŸ‘‡πŸ»
A destructuring assignment can save you a few lines of code, especially when you want to unpack multiple nested properties of an object. πŸ‘‡πŸ»
You can usually not destructure into existing variables.

But by putting parentheses around the statement, you actually can! πŸ‘‡πŸ»
You can also destructure arrays and extract individual values, as well as the remaining rest.

This is often more readable than accessing individual entries of the array. πŸ‘‡πŸ»
You can get the last items of an array by using slice with a negative number.

This returns an array with the number of items you specified with the respective negative number in the order they are placed in the original array. πŸ‘‡πŸ»
You can format the output of JSON.stringify by passing an indentation string as the third argument of the function. πŸ‘‡πŸ»
And that's it for now.

I hope you found something useful for you! πŸ’›πŸ™πŸΌ

β€’ β€’ β€’

Missing some Tweet in this thread? You can try to force a refresh
γ€€

Keep Current with Oliver Jumpertz

Oliver Jumpertz Profile picture

Stay in touch and get notified when new unrolls are available from this author!

Read all threads

This Thread may be Removed Anytime!

PDF

Twitter may remove this content at anytime! Save it as PDF for later use!

Try unrolling a thread yourself!

how to unroll video
  1. Follow @ThreadReaderApp to mention us!

  2. From a Twitter thread mention us with a keyword "unroll"
@threadreaderapp unroll

Practice here first or read more on our help page!

More from @oliverjumpertz

6 Jun
@ashnichrist Hey, Blockchain engineer and crypto investor here.

Sorry for the long answer, but I like to give people deeper information as crypto is both difficult and volatile.

I'd highly recommend you to start with actually finding out what lies below.

1/X

udemy.com/course/blockch…
@ashnichrist After this, the Binance Academy actually has awesome articles that at least touch the surface enough to be of real help.

2/X

academy.binance.com/de
@ashnichrist When you have an idea of what crypto approx. is, I'd start by getting into stable coins first.

Those are coins tied to some real-world value like the dollar or gold.

They aren't volatile, and you can still get pretty good interest rates with them.

3/X
Read 6 tweets
6 Jun
Here are 5 Svelte UI Libraries that will kickstart your next project!

πŸ§΅πŸ‘‡πŸ»
1️⃣ Svelte Material UI

Material is Google's UI design system.

Svelte Material UI brings this design system to you in the form of pre-made Svelte components.

sveltematerialui.com
If you love a flat design and are a huge fan of Material, you'll love Svelte Material UI!
Read 11 tweets
6 Jun
Here are a few essential tips that every aspiring or new web developer should take to heart.

πŸ§΅πŸ‘‡πŸ»
1️⃣ You Need To Know Way Less Than What You Think To Get Started

So many new developers think they need to become masters to be ready to apply for jobs or look for their first clients.

Here is the truth: This is wrong.
Do you have basic knowledge of HTML, CSS, and JavaScript? Great!

Can you create basic applications that do what they are supposed to do? Awesome!

If you can tick these boxes, start to apply!
Read 14 tweets
30 May
Okay, I'll give away another 30 copies of Pratham's cheat sheet collection.

If you can't afford or buy for some reason and still want to support @Prathkum, DM me your mail.

❗️ First come, first served ❗️

Answering and sending out might take some time!
I already have way more than 30 DMs. I will process them in the order I received them. πŸ™πŸ»

Give me some time, I'll notify anyone who managed to get one. ☺️
This is your lucky day. Thanks to @Prathkum, I'll give away 20 additional ones!
Read 7 tweets
30 May
AWS Lambda added container support some time ago.

We're going to look into what this offer actually includes and how we could build a containerized Lambda function ourselves. πŸ‘¨πŸ»β€πŸ«

Start your IDEs and open your AWS consoles because we're going in!

πŸ§΅πŸ‘‡πŸ»
1️⃣ AWS Lambda Previous To Container Image Support

Until recently, AWS Lambda only allowed you to write some code and upload a zip archive containing all files necessary to run your function.

Some frameworks eased up this process, but that's how it went.
Lambda also imposed some pretty strict limits, especially the 50MB default deployment size limit.

You could technically circumvent this limit by pulling more deployment dependencies from S3 or issuing an AWS Service Limits support request. But this wasn't the most...
Read 32 tweets
29 May
I love AWS Lambda. It's so easy to get a function up and running while AWS handles everything other than the code for you.

But where is your code actually executed? How does AWS do it?

Well, I took a deeper look and this is what Lambda's foundation is!

πŸ§΅πŸ‘‡πŸ»
1️⃣ Thinking about Lambda

We know that we can write a script that looks like below and then upload it to AWS while they take care of everything else.

And from simply looking at the code, it doesn't look like the usual API method we'd implement in Express. Image
We're exporting a function, so something else must take our code, import it, and handle everything else. πŸ€”

Conclusion number one:
Something must run our code.
Read 28 tweets

Did Thread Reader help you today?

Support us! We are indie developers!


This site is made by just two indie developers on a laptop doing marketing, support and development! Read more about the story.

Become a Premium Member ($3/month or $30/year) and get exclusive features!

Become Premium

Too expensive? Make a small donation by buying us coffee ($5) or help with server cost ($10)

Donate via Paypal Become our Patreon

Thank you for your support!

Follow Us on Twitter!

:(