No video

Logical Short-Circuiting in JavaScript

  Рет қаралды 5,593

Steve Griffith - Prof3ssorSt3v3

Steve Griffith - Prof3ssorSt3v3

Күн бұрын

There is a built-in behaviour in JavaScript designed to make it faster to process commands. If you combine two expressions with a logical AND operator, the JavaScript interpreter will look at the expression on the left side first. It will ONLY look at the one on the right IF the one on the left side evaluated to true.
Ternary Operator Video : • Javascript Ternary Ope...

Пікірлер: 16
@rotrose7531
@rotrose7531 4 жыл бұрын
A function that has no return statement will by default return undefined. This is now firmly remembered in my head. Thank you.
@remigiangolec7420
@remigiangolec7420 2 жыл бұрын
omg missed this valuable information at first viewing, only to discover the implications of it during logical operators practice days later
@jayster900able
@jayster900able 2 жыл бұрын
Love how you really explain things for newbie future devs!
@allenrichardyeager8449
@allenrichardyeager8449 3 жыл бұрын
Thank you so much, I read JS book and It's not clear about this topic. The way you explain short circuiting logical is open my mind. Great job 👏🏻
@cigarAsh369
@cigarAsh369 5 жыл бұрын
Thank you, sir. Very helpful
@chesterxp508
@chesterxp508 2 жыл бұрын
Another very cool tutorial !!!
@iredits7621
@iredits7621 3 жыл бұрын
It sounds like you are destroying your mouse everytime you click it lol. Very helpful video though, great job!
@SteveGriffith-Prof3ssorSt3v3
@SteveGriffith-Prof3ssorSt3v3 3 жыл бұрын
It was my old microphone picking up the trackpads clicks.
@maxtayebwa8987
@maxtayebwa8987 5 жыл бұрын
Very helpful indeed. Prof, would do a series on best code practices in JS and PHP? I really think it would be a great one! Thanks otherwise prof...
@SteveGriffith-Prof3ssorSt3v3
@SteveGriffith-Prof3ssorSt3v3 5 жыл бұрын
Thanks. Please post that on my tutorial request video
@badbeatslayer
@badbeatslayer Жыл бұрын
8:39 how is the f() returning "no" now? I watch it 3 times, can' understand ...help please !
@SteveGriffith-Prof3ssorSt3v3
@SteveGriffith-Prof3ssorSt3v3 Жыл бұрын
f() is writing 'yes'. g() returns undefined and then logs out 'no'.
@shinigami2669
@shinigami2669 4 жыл бұрын
does this work same when we use or(||) operator?
@SteveGriffith-Prof3ssorSt3v3
@SteveGriffith-Prof3ssorSt3v3 4 жыл бұрын
yes.
@bruhmoment3731
@bruhmoment3731 2 жыл бұрын
cool!
Composition vs Inheritance in JavaScript
12:23
Steve Griffith - Prof3ssorSt3v3
Рет қаралды 11 М.
Looping and Recursion in JavaScript
12:09
Steve Griffith - Prof3ssorSt3v3
Рет қаралды 8 М.
Little brothers couldn't stay calm when they noticed a bin lorry #shorts
00:32
Fabiosa Best Lifehacks
Рет қаралды 21 МЛН
Underwater Challenge 😱
00:37
Topper Guild
Рет қаралды 41 МЛН
Understanding the Keyword THIS in JavaScript
13:59
Steve Griffith - Prof3ssorSt3v3
Рет қаралды 9 М.
JS Function Methods call( ), apply( ), and bind( )
13:14
Steve Griffith - Prof3ssorSt3v3
Рет қаралды 38 М.
ES5 Custom Object Methods, Getters, and Setters
9:49
Steve Griffith - Prof3ssorSt3v3
Рет қаралды 12 М.
JavaScript Function Currying
11:41
Steve Griffith - Prof3ssorSt3v3
Рет қаралды 15 М.
Understanding Synchronous vs  Asynchronous JavaScript
15:38
Steve Griffith - Prof3ssorSt3v3
Рет қаралды 71 М.
JavaScript Array filter method
9:15
Steve Griffith - Prof3ssorSt3v3
Рет қаралды 18 М.
JavaScript Unicode Characters and Escape Sequences
10:22
Steve Griffith - Prof3ssorSt3v3
Рет қаралды 13 М.
JavaScript Object create method
5:08
Steve Griffith - Prof3ssorSt3v3
Рет қаралды 19 М.
JavaScript Chaining Array Methods and Using Arrow Functions
8:06
Steve Griffith - Prof3ssorSt3v3
Рет қаралды 12 М.
Ten Steps to Mastering the Fetch API
2:19:52
Steve Griffith - Prof3ssorSt3v3
Рет қаралды 44 М.
Little brothers couldn't stay calm when they noticed a bin lorry #shorts
00:32
Fabiosa Best Lifehacks
Рет қаралды 21 МЛН