Checking for the Existence of JavaScript Variables

  Рет қаралды 3,329

Steve Griffith - Prof3ssorSt3v3

Steve Griffith - Prof3ssorSt3v3

11 ай бұрын

When writing JavaScript there are going to be times when you want to use a variable or call a function, but you are not sure if it exists, then this is how you can handle these situations.
Code from video: gist.github.com/prof3ssorSt3v...

Пікірлер: 33
@SaadEdify
@SaadEdify 3 ай бұрын
Hello Professor Thanks for teaching us hope you are doing fine waiting for more tutorials and lessons.
@shahinza
@shahinza 7 ай бұрын
Hello Professor! I've truly missed your insightful videos. Your content has always been my go-to for simplifying complex topics. Hoping everything is going well for you. Looking forward to new uploads!
@SteveGriffith-Prof3ssorSt3v3
@SteveGriffith-Prof3ssorSt3v3 7 ай бұрын
Thanks. Just busy with work and writing a book on Flutter.
@cholo2605
@cholo2605 3 ай бұрын
We miss you prof3!!
@chiggywiggy524
@chiggywiggy524 2 ай бұрын
You're the Bob Ross of programming ❤
@anthonydsouza8202
@anthonydsouza8202 6 ай бұрын
Hi professor. Great to know that you are writing a book. Surely, it's gonna be as awesome as your videos. Wishing you all the best.
@Felipekimst
@Felipekimst 11 ай бұрын
Man, that wind out there got me scared lol
@SteveGriffith-Prof3ssorSt3v3
@SteveGriffith-Prof3ssorSt3v3 11 ай бұрын
That tornado actually hit across the street from my son.
@Felipekimst
@Felipekimst 11 ай бұрын
@@SteveGriffith-Prof3ssorSt3v3 jezzzz, hope everything is okay 🙏
@SteveGriffith-Prof3ssorSt3v3
@SteveGriffith-Prof3ssorSt3v3 11 ай бұрын
@@Felipekimst he was lucky. Just debris around his yard
@Felipekimst
@Felipekimst 11 ай бұрын
@@SteveGriffith-Prof3ssorSt3v3 good thing he's well
@NurioonSoftware
@NurioonSoftware 7 ай бұрын
Professor. Your channel is Diamond 💎
@St1diot
@St1diot 2 ай бұрын
I love you proffesor steve ❤❤
@nro337
@nro337 11 ай бұрын
Great video!
@Strasbourgeois
@Strasbourgeois 9 ай бұрын
A script of type module creates it's own scope preventing var declarations from bubbling up to the global scope
@shahinza
@shahinza 11 ай бұрын
Thank you 🙏
@leonardchan2638
@leonardchan2638 8 ай бұрын
There's an edge case where, you just declare a variable (but don't assign a value to it) let varname; and typeof varname is actually 'undefined'. So you can't re-declare it. Not practically useful though...
@rationalindianguy
@rationalindianguy 2 ай бұрын
Hello sir. You are doing amazing... please upload React
@SteveGriffith-Prof3ssorSt3v3
@SteveGriffith-Prof3ssorSt3v3 2 ай бұрын
I do have two react playlist. No NextJS yet but hopefully soon
@user-tt7po9td3x
@user-tt7po9td3x 8 ай бұрын
Hi Steve, great content. I was wondering if you could make a video on Promise polyfill using es6 classes. It's commonly asked in interviews
@SteveGriffith-Prof3ssorSt3v3
@SteveGriffith-Prof3ssorSt3v3 8 ай бұрын
I have not heard of that being asked in many years. Node and all browsers all support Promises and have for years.
@grenzhochspannungshindernis
@grenzhochspannungshindernis 10 ай бұрын
Can you recommend any how-to-program books?
@SteveGriffith-Prof3ssorSt3v3
@SteveGriffith-Prof3ssorSt3v3 10 ай бұрын
There are thousands. It depends on what specifically you are trying to learn. What language? What framework? What technology? I recommend going to a book store and spend a couple hours flipping through books on the topic you want to learn. Pick a book whose author writes in a way that you understand. It doesn't matter what book or what you are learning. As long as you are learning, you are making progress. Programming is a life-long learning process. Just start.
@mayankshashi5557
@mayankshashi5557 10 ай бұрын
Hi sir, can you please make a video on how we can display image on webpage when we upload image data into indexdb in offline mode?
@SteveGriffith-Prof3ssorSt3v3
@SteveGriffith-Prof3ssorSt3v3 10 ай бұрын
This video explains how to work with files and data to display things on a webpage - kzbin.info/www/bejne/sKKVqXdjrdp8fZY I do plan to make a video on how to save files with IndexedDB... not sure when but it is on my list.
@user-he1rz2bv9w
@user-he1rz2bv9w 2 ай бұрын
Hey steve, I'm 15 year old and I only just started learning programming, I want to make it a career out of it, is starting at 15 ideal and how many years will it take me on average to achieve an intermediate or advanced level??
@SteveGriffith-Prof3ssorSt3v3
@SteveGriffith-Prof3ssorSt3v3 2 ай бұрын
In my program, I've taught 17 year olds and 60 year olds. Both of whom did great. The best time to start learning how to program is today. The time required to get to an intermediate level depends on the person and how much time is spent learning and practicing through building things. Could be a year, or could be five years. You also have to consider intermediate in which area. There are lots of areas to learn about in programming. You can be a beginner in a dozen and intermediate in a couple, and advanced in a couple others.
@RalphGoddard-tt1xq
@RalphGoddard-tt1xq 11 ай бұрын
If your not already, you might want to use a noise cancelling mike
@SteveGriffith-Prof3ssorSt3v3
@SteveGriffith-Prof3ssorSt3v3 11 ай бұрын
I do but there was a Tornado approaching while I was recording. Seriously.
@bmehder
@bmehder 11 ай бұрын
@@SteveGriffith-Prof3ssorSt3v3 I was going to ask if you were recording the video during a tornado as a joke. Glad you made it through unharmed.
@atjustlookin
@atjustlookin 7 ай бұрын
The way you built out this object in this video kzbin.info/www/bejne/emqteZyweKarbrc, i am curious if one of your vids touch on the foundations on how to do this. I am having issues grasping how to fullt use objects like this or have than added or adding to a array and be able to manipulate them off of user input and doms. I am doing the form validation for Odin project and it brought me to your channel
@SteveGriffith-Prof3ssorSt3v3
@SteveGriffith-Prof3ssorSt3v3 7 ай бұрын
In this video kzbin.info/www/bejne/hKm5dKRqpZV-mJI I talk about building simple JS objects with the data from a form. In this video kzbin.info/www/bejne/fYitmXhtgc6WoNU I talk about simple work with FormData objects. I have lots of videos talking about basic work with JS Objects. There are lots and lots of things to learn about Objects. Maybe I will make a long 60+ minute video about all that object info combined into one place.
The Difference between JS Expressions and Statements
8:45
Steve Griffith - Prof3ssorSt3v3
Рет қаралды 6 М.
Deep Dive into Array from method
22:05
Steve Griffith - Prof3ssorSt3v3
Рет қаралды 2,6 М.
The day of the sea 🌊 🤣❤️ #demariki
00:22
Demariki
Рет қаралды 96 МЛН
WHO DO I LOVE MOST?
00:22
dednahype
Рет қаралды 79 МЛН
Дибала против вратаря Легенды
00:33
Mr. Oleynik
Рет қаралды 4,3 МЛН
1 or 2?🐄
00:12
Kan Andrey
Рет қаралды 31 МЛН
Revealing the Differences between HTML Dialogs and the Popover API
24:14
Steve Griffith - Prof3ssorSt3v3
Рет қаралды 7 М.
Up and Running with SQLite3 in a NodeJS API
47:16
Steve Griffith - Prof3ssorSt3v3
Рет қаралды 1 М.
Chrome Dev Tools Source Panel and Breakpoints
18:21
Steve Griffith - Prof3ssorSt3v3
Рет қаралды 5 М.
Introduction to Building Custom Web Components
13:02
Steve Griffith - Prof3ssorSt3v3
Рет қаралды 27 М.
Chrome Dev Tools Console Super Powers
16:44
Steve Griffith - Prof3ssorSt3v3
Рет қаралды 4,9 М.
Important differences between textContent and innerText
11:44
Steve Griffith - Prof3ssorSt3v3
Рет қаралды 2,2 М.
JavaScript Promises  -- Tutorial for Beginners
37:05
ColorCode
Рет қаралды 110 М.
Async JavaScript & Callback Functions -- Tutorial for Beginners
24:21
The day of the sea 🌊 🤣❤️ #demariki
00:22
Demariki
Рет қаралды 96 МЛН