filmov
tv
JavaScript Switch Statements - When to use switch over if/else?

Показать описание
Switch statements are a great way to direct application logic flow with conditional expressions. The tricky part with them though is that it's not entirely clear when developers should use switch statements. In this video, I'm sharing my opinions on when developers should use switch through my experiences with the JavaScript feature
Timestamp:
0:00 Introduction
0:33 Switch Statement Syntax
1:42 When should I use Switch Statements?
2:03 Example: Switch Statements used for Handling State
3:12 Convert Example: Switch Statement into if/else statement
4:13 Redux State using Switch Statements
4:49 switch Feature: return and break keywords
6:03 switch Feature: Multicases for Switch Statements
6:41 Switch Statements: Big Takeaway + Advice
7:28 Volunteer to the Igbo API
== Let's Connect ==
== Who I Am ==
I'm Ijemma, a frontend software engineer currently working in New York City. I make videos on all things JavaScript and, more broadly, frontend web development.
Icons from Freepik
#javascript #webdevelopment #softwareengineer
Timestamp:
0:00 Introduction
0:33 Switch Statement Syntax
1:42 When should I use Switch Statements?
2:03 Example: Switch Statements used for Handling State
3:12 Convert Example: Switch Statement into if/else statement
4:13 Redux State using Switch Statements
4:49 switch Feature: return and break keywords
6:03 switch Feature: Multicases for Switch Statements
6:41 Switch Statements: Big Takeaway + Advice
7:28 Volunteer to the Igbo API
== Let's Connect ==
== Who I Am ==
I'm Ijemma, a frontend software engineer currently working in New York City. I make videos on all things JavaScript and, more broadly, frontend web development.
Icons from Freepik
#javascript #webdevelopment #softwareengineer
Комментарии