let & const in JS 🔥Temporal Dead Zone | | Namaste JavaScript Ep. 8

แชร์
ฝัง
  • เผยแพร่เมื่อ 14 ต.ค. 2024

ความคิดเห็น • 1.2K

  • @parthajagiya4439
    @parthajagiya4439 3 ปีที่แล้ว +730

    so many things here. I would like to sum up in notes,
    -> let and const are hoisted. we cant use them before initialization is result of "temporal dead zone".
    -> js use diff memory than global execution context to store let and cost. which is reason behind "temporal dead zone"
    -> level of strictness ... var

    • @surajpatil3247
      @surajpatil3247 3 ปีที่แล้ว

      thanks

    • @surajpatil3247
      @surajpatil3247 3 ปีที่แล้ว

      @Akshay Saini pin this comment

    • @deependrakumar2019
      @deependrakumar2019 3 ปีที่แล้ว +42

      Just one correction let variable can be reinitialize.

    • @karljosebuena
      @karljosebuena 3 ปีที่แล้ว

      @@deependrakumar2019 thanks for the notes :)

    • @nikhil4844
      @nikhil4844 3 ปีที่แล้ว

      Thank you

  • @jagrutsharma9150
    @jagrutsharma9150 2 ปีที่แล้ว +541

    Things learned:
    1. let and const are hoisted but its memory is allocated at other place than window which cannot be accessed before initialisation.
    2. Temporal Dead Zone exists until variable is declared and assigned a value.
    3. window.variable OR this.variable will not give value of variable defined using let or const.
    4. We cannot redeclare the same variable with let/const(even with using var the second time).
    5. const variable declaration and initialisation must be done on the same line.
    6. There are three types of error: [1] referenceError {given where variable does not have memory allocation} [2] typeError {given when we change type that is not supposed to be changed} [3] syntaxError {when proper syntax(way of writing a statement) is not used}.
    7. Use const wherever possible followed by let, Use var as little as possible(only if you have to). It helps avoid error.
    8. Initialising variables at the top is good idea, helps shrinks TDZ to zero.

    • @omkarmankar1524
      @omkarmankar1524 2 ปีที่แล้ว +1

      Very Good Explaination

    • @rajendrasinghbisht5119
      @rajendrasinghbisht5119 2 ปีที่แล้ว +4

      Awesome Summary just like the video

    • @robertobenedit
      @robertobenedit 2 ปีที่แล้ว +1

      Bravo!

    • @gulz4u
      @gulz4u 2 ปีที่แล้ว +9

      @vipin here you are re initializing it and that is allowed in let but you cannot redeclare the same variable again. I hope this was what you were looking for.

    • @siddeeqsiddi7829
      @siddeeqsiddi7829 ปีที่แล้ว +10

      @@gulz4u let variable value can change without using let word again
      eg: let a=10;
      a=20;

  • @LifepartChandigarh
    @LifepartChandigarh 7 หลายเดือนก่อน +20

    I am 3 years of experienced react native developer. I learn JS from many youtubers, udmy plans many more but this is what i was looking for since 3.5 years.
    Dear new learner's you can blindly follow this guy. Really a gem 💎

  • @corporatetrainers3286
    @corporatetrainers3286 3 ปีที่แล้ว +100

    This is the best charity anyone can give. Thank you for not charging for these videos.

  • @ruchikasingh9220
    @ruchikasingh9220 3 ปีที่แล้ว +679

    Can't believe instead of Netflix I am watching javascript videos in free time...

    • @vitalvisions4U
      @vitalvisions4U 3 ปีที่แล้ว +16

      Same. Had plans for RAY on this weekend. Ending up watching 5 videos of this series.

    • @mizanur_sajid
      @mizanur_sajid 3 ปีที่แล้ว +3

      surely with no credit card 😬

    • @stevenedwards9262
      @stevenedwards9262 3 ปีที่แล้ว +6

      Much more valuable use of your time, id say

    • @hellonishant
      @hellonishant 3 ปีที่แล้ว +1

      same here

    • @valp_co
      @valp_co 3 ปีที่แล้ว +2

      This playlist is pure gold

  • @nareshbhati7527
    @nareshbhati7527 3 ปีที่แล้ว +29

    I really feel proud cos now we don't need to refer any tutorial form foreigner while we have best talent like Akshay. Salute bro.

  • @poornimank3672
    @poornimank3672 ปีที่แล้ว +20

    I failed in around 10 interviews last year but by just going through 4 vedios of yours ,I cracked the technical round and got selected. Thank you

    • @tusharikatejaswi5117
      @tusharikatejaswi5117 6 หลายเดือนก่อน +5

      if you donot mind mentioning those 10 faileinterview company names, we will apply now??

  • @akshaymarch7
    @akshaymarch7  4 ปีที่แล้ว +87

    Next Video: let & const Block Scope and Shadowing in JS 🔥 - th-cam.com/video/lW_erSjyMeM/w-d-xo.html
    How was this video? Are you feeling excited? Let me know in the comments below. ❤️

    • @samarth319
      @samarth319 4 ปีที่แล้ว

      Sir can you tell these videos are Beginners who wanna crack Js interviews or for those who just want to understand Js for web development and pickup any Js framework with ease? I just wanna know the target audience. Btw love the explanations!🙏

    • @ravipanchalvishwakarma
      @ravipanchalvishwakarma 4 ปีที่แล้ว +2

      plz Bhaiya jaldi jaldi videos upload kijiye ... i m so excited to learn JS properly.

    • @ayushjain7658
      @ayushjain7658 4 ปีที่แล้ว

      Hi Akashay , do interviewer ask about design pattern ? How important they are for a senior js developer and can you please upload something on design pattern .
      They are so confusing ..
      It will be a great .
      Thank you sir for your work i am following you from last one year your first vedio is the pivot point in my career

    • @KrishanKashyap108
      @KrishanKashyap108 4 ปีที่แล้ว +1

      Everytime see your video always learn something new... like in this video temporal dead zone.
      You are doing good work keep it up.
      Big big big thanks from my side.😍

    • @sauravkumarsharma9428
      @sauravkumarsharma9428 4 ปีที่แล้ว +1

      Sir one request please try to complete this series by November end if possible it will be very benifitial for me for my placement interviews as you cover everything in very detailed way which is not available anywhere else

  • @brahmanandas1909
    @brahmanandas1909 4 ปีที่แล้ว +50

    Basically am a java developer I never really liked js, but u just made me start loving it... ಧನ್ಯವಾದಗಳು❤️

    • @B-Billy
      @B-Billy 3 ปีที่แล้ว +1

      Same here... so much frustration.

  • @VikashKumar-ox2hv
    @VikashKumar-ox2hv 3 ปีที่แล้ว +94

    I think I was in " temporal dead zone " until this video was completed 🙏😀🙏
    Thank you so much all other concept I learned before strat watching your video made me fell now that I was in "Temporal dead zone".
    I really love having these concepts over watching movies and series on Netflix, you making my interest going far and far Brother.
    ❤️I ALREADY FALL IN LOVE WITH JAVASCRIPT ❤️JUST BECAUSE OF YOU BROTHER period.

  • @renatoalves92
    @renatoalves92 3 ปีที่แล้ว +92

    I have been studying these concepts for the past few weeks and was already starting to feel stuck, until I found your videos by chance. His explanation is impeccable. I'm following this playlist firmly. Thanks!

    • @yupp_harish3936
      @yupp_harish3936 11 หลายเดือนก่อน

      dude namaste js is free or there is paid version also of namaste js??and is this js series complete or incomplete ...is namaste js series a complete series of js topics??

  • @SameeraPkChannel
    @SameeraPkChannel 3 ปีที่แล้ว +139

    I guess if u take any JS interview then nobody in this world would get hired .Absolutely amazing tutorials bro .Keep going 😊😊😊

    • @akshaymarch7
      @akshaymarch7  3 ปีที่แล้ว +42

      Haha, nothing like that brother.. 😅

    • @robingupta7895
      @robingupta7895 3 ปีที่แล้ว +10

      No, Not like that
      I think he will hire the best person...

    • @gajananlimbale670
      @gajananlimbale670 3 ปีที่แล้ว +3

      😂😂

    • @mahimak5736
      @mahimak5736 3 ปีที่แล้ว +29

      We can clear his interview after watching all his videos 🤣

    • @rishitiwari6200
      @rishitiwari6200 3 ปีที่แล้ว +22

      @@mahimak5736 he be like:Mera maal mere ko hi bech rha

  • @shaileshkamble8730
    @shaileshkamble8730 ปีที่แล้ว +4

    I have been studying these concepts last one year but now I understood all Advance JS concepts through visualization . Thanks . your efforts are appreciable .

  • @chandanabr473
    @chandanabr473 2 ปีที่แล้ว +1

    i was really confused about let and const hoisting when my trainer asked me. And your video explained everything about it . Now am confident about these concepts. Thank you namasthe js

  • @Kirti-bi2yj
    @Kirti-bi2yj 2 หลายเดือนก่อน +10

    Here is the full notes of the video :
    1. "let" and "const" declarations are hoisted, but they are hoisted very differently from the "var" declarations.
    2. Memory is assigned to "var" declarations, and "var" declarations are always attached to the global object "window". In case of "let" and "const", they are allocated memory in some different memory space other than global space known as "Script", and this is what we call hoisting. The "let" and "const" declarations are not attached to the global object "window". And this is the reason you cannot access these "let" and "const" variables before you have put some value in them.
    3. Temporal dead zone is the time since when "let" & "const" variables were hoisted (set as "undefined") and till it is initialized with some value, the time between these two phenomena's is known as the Temporal Dead Zone. Whenever you try to access a "let" or "const" variable in the temporal dead zone, then it will always give you reference error.
    4. var declarations are always attached to the window object, provided they've been declared in the global scope. let and const declarations are never attached to the window object, as these variables are never stored in the global memory space.
    5. let and const are more strict than var. Re-declaration of let is not allowed in JS. The JS engine will give a syntax error, it is not allowed in the same scope.
    6. How to avoid temporal dead zone?
    Sometimes the temporal dead zone can mess our code as a developer. The best way to avoid the temporal dead zone is to always put your declarations and initializations on the top of the code. So, that as soon as your code starts running, it hits the initialization part at the first, and then you go into the logic, and then you do something with these variables. Otherwise, you'll run into unexpected errors in your code.
    This way we're shrinking the temporal dead zone nearly to zero. We've minimized the TDZ nearly to zero, while moving all the initializations at the top, so that nothing happens before these initializations.

  • @SemicolonGuy
    @SemicolonGuy 3 ปีที่แล้ว +7

    Watching whole series the second time just before my interview ❤️

  • @jayjani740
    @jayjani740 4 ปีที่แล้ว +13

    All your videos help me out discover many new things which I could have never figured out by myself at this particular time. Thanks alot, Akshay. 🤩
    DOUBT:
    let and const refer to Script, right! So what's the relation between Script and Window? Because we can reassign values to let objects into the functions defined in Window scope.

  • @rajatshrivastava879
    @rajatshrivastava879 3 ปีที่แล้ว +1

    These are insane teaching skills. I have been dropped in 3 interviews bcs of scope output questions. Now, i explain then how sizes are allocated within different scopes.

  • @VipulDessaiBadGAMERbaD
    @VipulDessaiBadGAMERbaD 2 ปีที่แล้ว +4

    Temporal dead zone is the time between the variable scope creation and its initialisation, that is why let,const will throw error when they are put outside of some blocks (i.e. global context which is not lexical), that is why if you just surround let, const with blocks then their scope will be a block scope and its created and then they wont throw error coz now your accessing them after the time of their scope creation

  • @sougandikal6022
    @sougandikal6022 3 ปีที่แล้ว +7

    Temporal dead zone: Time gap between the variables hoisted and its initialization, Understood clearly about it Thank you Akshay Stay blessed :) :)

    • @vishalgoel6323
      @vishalgoel6323 3 ปีที่แล้ว

      Shouldn't it be declaration instead of initialisation ?

    • @paisastocks8363
      @paisastocks8363 2 ปีที่แล้ว

      @@vishalgoel6323 It should be initialisation only.

  • @chinmaydas4053
    @chinmaydas4053 3 ปีที่แล้ว +4

    The legend of JavaScript..no one can teach us in such a intricate details in this world..lots of love and respect for you brother 🙏🙏..

  • @rahulsoni292
    @rahulsoni292 3 ปีที่แล้ว +1

    Instead of buying any course i will learn from your videos
    Thanks for sharing such valuable knowledge bhai

  • @dhawaltiwari6193
    @dhawaltiwari6193 3 ปีที่แล้ว +9

    This tutorial is the best for the beginners, because it laterally makes coding fun!!..........Are you going to make any content on ES6 and react??

  • @ASeaker
    @ASeaker 4 หลายเดือนก่อน +1

    Seriously you are very good at explaining the difficult concepts with live examples

  • @naveenkumarpulikonda1998
    @naveenkumarpulikonda1998 3 ปีที่แล้ว +7

    one of great videos that i have seen on JavaScript, before coming to this channel i was searching on udemy, LinkedIn learning for the best courses, but i found this course, from that day i have never searched for any other course
    Thank you Akshay Saini for wonderful content....🤗🤗🤗
    Try to make some videos on JavaScript logical questions, so that it helps us to understand these concepts in a practical way
    Today I Got my offer letter because of your videos....

    • @akshaymarch7
      @akshaymarch7  3 ปีที่แล้ว +1

      Wow, Congratulations brother! ❤️

  • @ghostrAider98
    @ghostrAider98 10 หลายเดือนก่อน

    Lots to learn from this video. Would like to add a small detail:
    If they(let and const) are declared in a block, they don’t get hoisted at all, they will get memory allocation(not assignment) when their block actually starts during execution phase. Try the function below and notice the memory allocation in dev tools
    function abc(){
    debugger;
    var a=10;
    let b=20;
    const c=30;
    if(true){
    debugger:
    var x=10;
    let y=20;
    const z=30;
    }
    }

  • @universal4334
    @universal4334 4 ปีที่แล้ว +23

    Finally got relief 😁 . Daily twice when I woke up I I'll check the channel for new video and when I am going to bed again I I'll do the same . Please upload daily bro 😑😑😑.

    • @akshaymarch7
      @akshaymarch7  4 ปีที่แล้ว +80

      Apologies brother, I got busy with the festivals and was not able to make new videos.
      Thank you for so much excitement, it motivates me to make more videos quickly. ❤️
      I'm trying my best, but still cannot make one video in a day along with my job. It takes a lot of time to prepare content, then record video, then edit the video and then upload and release it.
      Somtimes, if the video doesn't come out good, I have to reshoot that part. It takes time.
      But I'll try my best to come back as fast as possible.
      Thank you for your support. 😇

    • @imnothing2infinite
      @imnothing2infinite 4 ปีที่แล้ว +1

      @@akshaymarch7 thank you for your efforts, still I will be checking your channel is there any new video ❤️❤️❤️

    • @nike0822
      @nike0822 4 ปีที่แล้ว +1

      @Akshay Saini Love your efforts & yeah it's not easy to dive deep into these concepts and make a video every day! More power to you man! Take care. I'm really liking your way of teaching.

    • @funtoday5415
      @funtoday5415 3 ปีที่แล้ว +1

      Hello @@akshaymarch7, can you please make a video series on backend(.net c#, mvc controller) web development as well . Your explanation is amazing.

  • @TheDhanush
    @TheDhanush หลายเดือนก่อน

    I came from swift and PHP background and I clearly understand Javascript with you exceptional teaching. Thanks for the videos. Looking forward to other videos.

  • @rhimanshu6288
    @rhimanshu6288 3 ปีที่แล้ว +4

    Bhai bhai bhai.....What a concept clearance man🙌🏻. I took udemy courses of 50hr messed up duration but the core fundamentals are here in just 5 hrs for free. Thats the difference

    • @akshaymarch7
      @akshaymarch7  3 ปีที่แล้ว +13

      Not everything which is Free is useless ❤️

  • @yourfriendnur
    @yourfriendnur 2 ปีที่แล้ว +1

    Before watching these videos I could write basic javascript code but I didn't know these important things. Now I think theses are the most important things which should be known to us. So Thank you very much sir❤❤.

  • @sarav-Frontend_Engineer
    @sarav-Frontend_Engineer 2 ปีที่แล้ว +4

    Didn't heard about this terminology "Temporal Dead Zone" before but now I know it and can explain to anybody because of the great Mr.Akshay 😃

  • @frank3481
    @frank3481 3 ปีที่แล้ว

    This is literally the best explanation of Hoisting & errors for var, let and const in the world.
    Why is it sometimes 'is not defined ' and ' Reference Error cannot access before initialization '?
    The error message shows differently with the same code.
    Are they the same thing?
    ex)
    console.log(a); // is not defined or cannot access before initialization
    let a = 10;

  • @deepjyotkaurbindra
    @deepjyotkaurbindra 3 ปีที่แล้ว +3

    I have never come across such high-quality content on JS. Thanks for digging so deep.

  • @TW-uk1xi
    @TW-uk1xi 7 หลายเดือนก่อน

    The level of understanding you have is mind blowing.

  • @adabus8779
    @adabus8779 3 ปีที่แล้ว +8

    @4:20 Hey bro! Really enjoying this indepth content for javascript! I just wanted to point out a small error,
    You said that it is not possible to access the let and const declarations before you put some value in them. Well you could access let variables memory space without putting any value in them provided that it precedes the usage of the variables:
    let a;
    console.log(a);
    a=10;
    output=>
    undefined

    • @exodion4173
      @exodion4173 2 ปีที่แล้ว +1

      Good catch.
      Not that this is for let only. For const, since we hv to initialize them during declaration this wont be possible.

    • @ycombinator765
      @ycombinator765 2 ปีที่แล้ว +1

      good catch indeed. I have a tentative explanation.
      what if 'a' that we are accessing is not the one declared with let but the one which we attach to global 'window' object. see.
      console.log(window.a)
      outputs 'undefined' as well.
      here we didn't declare any 'a' with let.

    • @benbrahimilias426
      @benbrahimilias426 ปีที่แล้ว

      @@ycombinator765 exactly, it's like declaring a new variable

  • @baishakhinandi3635
    @baishakhinandi3635 2 ปีที่แล้ว

    As I am a web designer I should have knowledge about all JS frame work but I have less knowledge in JS. But now I falling in love with this after wathich your videos, and practising accordingly.Best teacher ever. Thank you very much

  • @dademix
    @dademix 3 ปีที่แล้ว +5

    Boy this stuff is truly amazing and is super valuable! These are the missing parts I never really understood and understanding those concepts makes everything about JavaScript so much easier and clearer.

  • @thekingraghuraman
    @thekingraghuraman 2 ปีที่แล้ว

    A small fact I would like to point out is instead of saying let should be initialized, we need to say declared. What I mean is
    console.log(a) // Would throw ReferenceError here
    let a;
    console.log(a); // will print undefined , same as var
    a = 'Hi';
    console.log(a); // will print Hi
    Great Video

  • @aayush5474
    @aayush5474 4 ปีที่แล้ว +20

    i am addicted to this series! Can't wait for next one! Making notes with every episode :)

    • @akshaymarch7
      @akshaymarch7  3 ปีที่แล้ว +7

      Oh, wow! That's great, it's a very good way to remember things. 😇

    • @sriramray4694
      @sriramray4694 หลายเดือนก่อน

      kya aap notes send kar sakte hai

  • @fahadpiash1515
    @fahadpiash1515 11 หลายเดือนก่อน

    i have been struggling so many years to fix how things happened behind the screen but now its very clear to me . became a big fan of yours .. thanks a lot .

  • @shreedevijamakhandi1877
    @shreedevijamakhandi1877 4 ปีที่แล้ว +7

    Without watching video first I like the video
    Always love ur video with good information

    • @akshaymarch7
      @akshaymarch7  4 ปีที่แล้ว +2

      Thank you so much, @Shreedevi. It means a lot. ❤️

  • @anshikgupta2993
    @anshikgupta2993 2 ปีที่แล้ว +1

    This is the best JavaScript course, I really wonder how did you learnt so much deep.

  • @shovarajouria110
    @shovarajouria110 3 ปีที่แล้ว +10

    Just a request , after completing this course could you explain how css works in detail ! Amazing content as usual

    • @drafercuber9943
      @drafercuber9943 3 ปีที่แล้ว

      Can I

    • @akshaymarch7
      @akshaymarch7  3 ปีที่แล้ว +16

      Added to my list, will try to cover that also. 😇

    • @soulseller1838
      @soulseller1838 2 ปีที่แล้ว

      @@akshaymarch7 Is it still on list?

    • @madeinscript4623
      @madeinscript4623 3 หลายเดือนก่อน

      ​@@akshaymarch7sir hope ur list will be made soon

  • @stark469
    @stark469 2 ปีที่แล้ว +2

    That explanation and coding demo of ReferenceError, TypeError, SyntaxError was amazing

  • @varnikaraghav3781
    @varnikaraghav3781 3 ปีที่แล้ว +4

    Make more videos on js concept for interview perspectives. The way you explain everything was great!

    • @akshaymarch7
      @akshaymarch7  3 ปีที่แล้ว +1

      Thank you so much, Varnika. Your comment motivates me to make more videos. ❤️

  • @jyotipatnaik336
    @jyotipatnaik336 3 ปีที่แล้ว

    Dude...You nailed it.. Itna acha clear explaination h.....jitne bhi JS k videos dekhe usme se tumhare video k level ka koi bhi nai match kr paya.

  • @avikkarmakar6333
    @avikkarmakar6333 2 ปีที่แล้ว +5

    I genuinely appreciate your efforts of making the concepts clear to us.. thank you so much for the series, I'm learning a lot

  • @sahilambekar6854
    @sahilambekar6854 2 ปีที่แล้ว

    every time i think that its just a basic video and i know all about this topic, but after watching your video on same topic i found that there are tons of things to learn which were abstracted in our day to day work

  • @VIDLIKER
    @VIDLIKER 3 ปีที่แล้ว +6

    Till date..in every interview I have answered to interviewer that var is hoisted and let and const are not hoisted😅....because in youtube and web people told the same🤣....Awesome video Akshay Bhai🤟🤟👍...eagerly waiting for next video

    • @akshaymarch7
      @akshaymarch7  3 ปีที่แล้ว +4

      I see a lot of people doing that. 😅
      But don't worry, now you know what to answer. 😉

  • @1990darsh
    @1990darsh 5 หลายเดือนก่อน +1

    Hi @akshaymarch7,
    One correction is there for the temporal dead zone, it is not mandatory to assign a value if use let for declaring a variable. . So temporal dead zone exists until variable is declared that's it. Without assign value we can access it. Even I learn this from your video only so thanks to you .

    • @bhushanambhore8378
      @bhushanambhore8378 5 หลายเดือนก่อน

      1. console.log(a1);
      2. let a1;
      here a1 in line 1 is in TDZ, as u said Without assign value we can access it. but we cant access it as it is giving ReferenceError

  • @0xFOXHOUND
    @0xFOXHOUND 3 ปีที่แล้ว +15

    For revision:
    always keep your variable declaration on top! on top!
    is 'let' and 'const' functions are hoisted? > Yes (but in temporal dead-zone)
    take a sample program
    console.log(b);
    let a= 10;
    var b= 100;
    we made var declaration to 'b' and let to 'a' and here comes the difference: the var declaration will come under global declaration and let declaration in script (separate memory space) and these variables are not accessible unless they are assigned with certain values
    so the temporal dead zone is the time between saving variables in memory-space and actually value assigned to it by engine itself. In this time frame you can't access the variable, by hoisting, Engine stores the Variable in 'Variable environment'(Memory component) and until the line where the actual variable is assigned to its value (until then variable, remains in temporal dead zone)
    ReferenceError cannot access before initialization : avoided the concept of temporal Dead zone, bound you will get this error!
    Q)How it differs from "Uncaught ReferanceError : X is not defined at .js" ?
    A> so it comes to a question "is variable X is in Variable environment ?"
    >> if(true);
    {
    console.log("cannot access before initialization");
    console.log("This is temporal dead zone case");
    }

    if(false);
    {
    console.log("Uncaught ReferanceError : X is not defined at.js");
    console.log("Variable is simply not available");
    };
    Q) and what about variable declared by 'var'?
    > they will assigned 'undefined' until a value is assigned
    Declaration Type
    var = saved in Global execution context, can be assigned later and modified in script.
    let = saved in script execution context, temporal deadzone affects it and can later modified in script.
    const= saved in script execution context, temporal deadzone affects it and must be defined (assign values) when defining variable by it (cannot remained as 'undefined').

    • @akshaymarch7
      @akshaymarch7  3 ปีที่แล้ว +10

      Write a blog brother, this effort of yours might get lost in so many comments.
      BTW love your dedication, you're a gem! 💥

    • @aliadel1723
      @aliadel1723 2 ปีที่แล้ว

      thank you ♥

  • @vinodgodti9301
    @vinodgodti9301 4 ปีที่แล้ว +1

    I love your depth knowledge of java script. "use const first and then let for variable declarations in day to day coding" this should be followed by every js developer.Hats off for your efforts to make this kind videos.👌👌👌👌

    • @akshaymarch7
      @akshaymarch7  3 ปีที่แล้ว

      Thank you so much for your comment, Vinod. It motivates me. 😇♥️

  • @kuntalbhattacharyya7614
    @kuntalbhattacharyya7614 3 ปีที่แล้ว +4

    "temporal dead zone" is the time since when the let variable is hoisted and till it is initialized to some value, the time between that is known as the temporal dead zone.

  • @ShivamSingh-wy8om
    @ShivamSingh-wy8om 3 ปีที่แล้ว

    Your explanations changed my view point of javascript. . . From hating it i have started loving it.

  • @dibyendubiswas1998
    @dibyendubiswas1998 3 ปีที่แล้ว +4

    #LovingIt.
    When I read this concept in book, then I am bored but today I am not bored.

  • @rashmi5635
    @rashmi5635 3 ปีที่แล้ว

    Earlier in the past everytime I will read the documents to understand the concept of let,var and const but after seeing this video and writing down the notes shrinked the repeated effort.Amazing content.

  • @Kirti-bi2yj
    @Kirti-bi2yj 2 หลายเดือนก่อน +3

    I literally started dancing on the tune at the end.😂

  • @anjalimaurya7598
    @anjalimaurya7598 3 ปีที่แล้ว +1

    every songs in the end of video hear like word namaste javascipt lyrics with superb music tone
    .

  • @jenwinjesswin
    @jenwinjesswin 3 ปีที่แล้ว +1

    Man O Man! I was confused between let, const, and var also even if they are hoisted or not?
    This video cleared my each and every doubt about them. Not just this but all the videos have solved all my doubts.
    Thank you so much for this. We have such a good playlist to watch and learn, I wonder how did you learn all these things in such depth.

  • @afaquezia
    @afaquezia 3 ปีที่แล้ว +4

    yes sir! I understood the temporal dead zone very clearly. thank you a lot sir and Very happy diwali.

    • @akshaymarch7
      @akshaymarch7  3 ปีที่แล้ว +1

      Happy Diwali Afaque. 😇

    • @afaquezia
      @afaquezia 3 ปีที่แล้ว +1

      @@akshaymarch7 thank you so much sir..Nobody teaches with such depth

  • @drapala97
    @drapala97 3 ปีที่แล้ว

    I am very grateful for your videos, Akshay Saini!
    *below is a personal note to myself
    1) compilador aloca espaço na memória para as declarations (var, let, const, function declaration, e class declaration), isso se chama hoisting.
    2) enquanto var é indexada no objeto global, let e const ficam na temporal dead zone
    3) por estar no objeto global, o acesso à var é permitido, entretando seu valor é undefined até ocorrer o assignment
    4) enquanto não ocorrer o assingment à let e const, elas continuam na temporal dead zone, e enquanto estão neste local, o acesso à estas declarations é impedido (unitialized)

  • @SnehJoshi19
    @SnehJoshi19 4 ปีที่แล้ว +3

    Waited for long😍

  • @tecres9379
    @tecres9379 2 ปีที่แล้ว

    Temporal dead zone is like a coma state , its there but you cannot talk to him, till the time he/she has been given value of life, Great explanation , we all owe you for deep diving into Concepts

  • @ashishkumarsharma404
    @ashishkumarsharma404 4 ปีที่แล้ว +3

    When you said let and const have block scope , block scope, block sock, it sounded like mujhe drugs do, drugs do , drugs do :P

  • @Shirishamutyala
    @Shirishamutyala 8 หลายเดือนก่อน

    I have been watching your videos from the beginning and taking notes.Completely addicted to these videos to that level even though I’m doing other works the concepts are running at the back of my head.Thanks brother

  • @grigortamazyan
    @grigortamazyan 3 ปีที่แล้ว

    I'm studying at a Computer Science School, and I told all other students about this channel, Namaste JavaScript ))))

  • @mihirverma21
    @mihirverma21 3 ปีที่แล้ว

    I am becoming your admirer by watching this series because you are giving us very deep knowledge about javascript.. thanks..❤️🙏

  • @aleemnasiyathulla8158
    @aleemnasiyathulla8158 2 ปีที่แล้ว

    I completely understand how the temporal dead zone is working. I am getting more confident after looking at your javascript videos. Thanks for this wonderful video.
    🙏🙏

  • @palakjain7612
    @palakjain7612 10 หลายเดือนก่อน

    Sir your way of explaining the very difficult topic to the very least difficult way is beyond imagination i have also seen your namaste react and really got to learn a lot thank you so much...........

  • @aniketshukla8085
    @aniketshukla8085 ปีที่แล้ว

    You have done real autopsy of Javascript. Now things are so so so easy to visualise that i dont have to remember anything.
    Thank You so much!!!

  • @rohanrana187
    @rohanrana187 ปีที่แล้ว

    No webseries watching , now watching only Namste Javascript Series , Thanks Akshay Saini no one can explain this thing in a very easy manner , learned lots of new things and fundas

  • @shekhargupta5307
    @shekhargupta5307 3 ปีที่แล้ว

    I like your way pf teaching, pehli bar basic itne acche se clear ho rahe h, nice bro

  • @Lalit_Shirsath
    @Lalit_Shirsath 3 ปีที่แล้ว

    I havent seen any teacher with such a enthusiasm ever. Hats off to you sir. You made our javascript journey so much easy

  • @asishraz6173
    @asishraz6173 3 ปีที่แล้ว +1

    Wowwww.
    LET,
    CONST,
    TEMPORAL DEAD ZONE
    REFERENCE ERROR
    GLOBAL OBJECT
    TYPE ERROR
    SYNTAX ERROR
    Now I am ready for interview.

  • @SAYANDAS-rp8er
    @SAYANDAS-rp8er 3 ปีที่แล้ว

    1st of all I would like 2 tell you tht this is mah 1st TH-cam commnt in my entire life regarding any topic. Now coming 2 the main point, I must appreciate your intention and your passion towards technology and javascript Community. It will be a great experience to see you as it is in upcoming years. Best wishes nd Standing Respect 2 your thought process and energy to serve community..🙏👍

  • @tauseefakhtar681
    @tauseefakhtar681 2 ปีที่แล้ว

    Awsm Akshay sir! I am 30 years old and trying to enter in React js field and really ur videos are very helping me. You r doing very divine job may God bless you❤️🙏😇

  • @khalidben9940
    @khalidben9940 2 ปีที่แล้ว +2

    This man is really a fantastic teacher.I congratulate you for this level of understanding and explaining.

  • @ArmanAli-st7ue
    @ArmanAli-st7ue 3 ปีที่แล้ว

    Thankyou for explaining in so deep
    M a developer and start learning js
    I scroll so many videos on TH-cam but all follows the same pattern like class teacher did in college time😀
    No one covers this much deeper
    Thanks a lot Akshay🙂🙂🙂

  • @Rajveer__singhhhh
    @Rajveer__singhhhh 8 หลายเดือนก่อน +1

    Yahoo baba, code with Harry , hitesh choudhary, Akshay saini javascript master teacher❤

  • @ikennanwachukwu4904
    @ikennanwachukwu4904 4 หลายเดือนก่อน

    briliantly explained concepts. I have just understood hoisting perfectly

  • @mohdabdulraheem9357
    @mohdabdulraheem9357 3 ปีที่แล้ว +2

    After a long time now I can saw I have the clarity between const, let and var. Thanks for the video.

  • @nishu20501
    @nishu20501 ปีที่แล้ว +1

    Amazing and loved the way you explained the concept with that depth.
    I am not from a CS background but i am learning full stack development. I found your playlist about a month ago and i just loved it.
    I rewatch many of your videos just to revise the concept.
    Thanks for this series.
    Really amazing work.

  • @harshdobariya3327
    @harshdobariya3327 ปีที่แล้ว +1

    content - amazing
    energy - hats off
    music at the end - vibe he

  • @sameer1571
    @sameer1571 3 ปีที่แล้ว

    Aap samjhao aur hume samjh na aaye aisa ho sakta hai love u sir for the knowledge you are sharing

  • @sarthakdua4589
    @sarthakdua4589 3 ปีที่แล้ว

    Never really knew earlier why do we get those reference errors. This video has given me the answer after 3 years of using them. Keep up the good work and keep sharing your tutorials brother!

  • @hercules2170
    @hercules2170 3 ปีที่แล้ว +1

    You really weren't kidding when you said "Let me tell you something interesting"
    Good stuff..Learned a lot from this video

  • @manjeshsingh3002
    @manjeshsingh3002 8 หลายเดือนก่อน

    seen playlist of other tutors but Akshay gives the best clarity. Thanks man

  • @Niggeshwar69
    @Niggeshwar69 2 ปีที่แล้ว

    i currently enrolled reactjs course from udemy in excitement and was not understanding core concepts of js and thought i wasted my money, then i found ur vids now course again feels worth and understandable, thank you for the great explaination

  • @funcreator46
    @funcreator46 3 ปีที่แล้ว

    If anyone wakes me up and ask me all these questions, I can confidently answered them even if I'm in deep sleep, I'm very dumb in Javascript but because of your way of explanation I fell in love with JS❤ and with your teaching❤😍

  • @manavdesai4280
    @manavdesai4280 3 ปีที่แล้ว +2

    Love the series Akshay ...... Been trying to shift to JS from Java and this series helps me understand how JS execution works like a breeze .Thank you for taking out time to do this. Helping a lot ❤️

  • @mercypill124
    @mercypill124 9 หลายเดือนก่อน

    just love this video.......................firstly i was very confused with scope of let and var but after seeing this video all my doubts are cleared

  • @shubhamsomani760
    @shubhamsomani760 3 ปีที่แล้ว +1

    I love the way you are teaching...lots of love from my side...

  • @vidhoo29
    @vidhoo29 2 ปีที่แล้ว

    As you explained const we should use in first place when we don't have to change the value frequently. But same thing is happening with let also.We can't redeclare let again.

  • @chandachandramahesh795
    @chandachandramahesh795 5 หลายเดือนก่อน

    very well understood the temporal dead Zone concept, and your smile gives me the positive vibes

  • @theyashgaur3236
    @theyashgaur3236 2 ปีที่แล้ว

    no one teachers these concepts clearly..
    thanks for these videos bhaiya..

  • @mayanksahu6486
    @mayanksahu6486 3 ปีที่แล้ว +1

    never seen such kind of explanation ever before in any tutorial. You are truly a gem. Thanks for making this amazing series. May God bless you

  • @trailblazer555
    @trailblazer555 4 หลายเดือนก่อน

    Understood the basics very well explanation!!! Namaste Javascript

  • @shubhcreater878
    @shubhcreater878 ปีที่แล้ว

    Aapka javascript lecture bole to Ek no Sir
    Kya aap Angular ke liye video bna sakte h sir

  • @prakalpvarshney8659
    @prakalpvarshney8659 3 ปีที่แล้ว

    I was already in love with JS... but i was unaware of these concepts...Ek tarfa pyaar ko do tarfa kardia aapne...A Huge Thanks!!!

  • @mukeshkrmandal8642
    @mukeshkrmandal8642 ปีที่แล้ว

    brother your way of explaing is far good as compare to any another youtube i am viewing your video after 2 yr but the way is non comparable to another