The "this" Keyword - Javascript In Depth

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

ความคิดเห็น • 42

  • @vladim0rt1
    @vladim0rt1 11 หลายเดือนก่อน +4

    This whole playlist has been so good, thank you so much for this gem

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

    it was next level tutorial

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

    I love how you explain things both graphically and in IDE. It's easy to understand yet in-depth. Thank you so much for clarifying THIS concept.

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

      You're very welcome! I'm glad the combo of visuals and code helps along with the exercises! Don't hesitate to let me know if there are topics you think might be useful to cover too 😊

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

    Damnit Nader, you did it again. Took a concept I thought I already knew and taught me a bunch more about it... Gold

  • @nanlunglongtau2076
    @nanlunglongtau2076 8 หลายเดือนก่อน +2

    Discovering this channel is like discovering gold

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

    Fantastic explanation of "this" keyword.

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

      Thanks Abdullah! It was tricky putting this together to focus on the important parts - I'm glad it ended up well and is useful for everyone! 🤗

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

    best teacher! hands down! :)))

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

    For a beginner level it's good
    was expecting a little more from this tutorial with respect to scopes and function context

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

    WonderFull explanations , it is like zero to hero camp

  • @eduardoontiveros-oi5ej
    @eduardoontiveros-oi5ej 2 หลายเดือนก่อน

    I'm so thankful you made this series. and the exersises it has been incredible help to nail and sollidify all the concepts i had doubts with

    • @eduardoontiveros-oi5ej
      @eduardoontiveros-oi5ej 2 หลายเดือนก่อน

      i did some exersises during the video prior to the video following this one. i was playing around with arrow functions and their scope and made a little exersise that made me learn that only functions have a scope so i found a use for arrow functions in conjuction with the keyword this and it was awesome. thanks for the series

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

    WoW again concepts cleared! Thanks Sir!
    Pls keep making videos! I've subscribed too!!!

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

    Excellent Teaching Nader, love the way you explained 'this' !! thank you for this

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

      Thanks! This is a tricky one, haha! Glad it makes more sense, it was fun to try to figure out how best to explain it so I'm glad it came across well 😊

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

    This is a great lesson, you helped me so much!

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

      Thanks Filip! I’m glad you found it helpful - this is a notoriously tricky topic, haha! 😊

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

    Bro just keep posting video like this you're really good at explaning javascript and always put some exercise to refresh more of our brain. See you on the next vid gain

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

      Thanks Carl! I really love making these and contributing to the community as it seems like there is a gap for such content. I can't wait to get to other topics too like the front-end, back-end, databases etc 🤩
      Hope you enjoy the upcoming exercises for "this" (I got a little too excited making them)! 🥳

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

      @@TechWithNader Nice vids bro I hope you can explain topics about front end like integrating javascrip to to html and css and library like react js

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

      Yup, those are coming soon after we are done with the core of JS 😊

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

    Thank you for your work 👏

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

      Hey Alvee! You're very welcome! 😊

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

    Love your videos. Error at [53:17].
    storm.greet.call({name: "Wolverine"}) prints out:
    { name: 'Wolverine' }
    Wolverine says hi
    NOT
    Hero { name: 'Wolverine', greet: [Function (anonymous)] }
    Since the context has been replaced by .call(), the greet function no longer exists in "this".

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

    Brother in your js course you have solve most of the "return" problem but as a junior developer I always stuck with this "return" please make a depth video of it, I think developer community need it

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

      Do you mean "return" inside functions? It's definitely a tricky one to get used to in all cases, so I'll think of some more advanced cases for it to see if I can help. Not sure if you watched how we used them in the Closures videos and examples? That was also a more advanced use case 😄
      Also, not sure if I shared this with you, but feel free to join our Discord so you can also get quick help with questions like this if I don't have a video on it yet: discord.gg/K4nkugP7Gd
      I can't wait to make more videos for our community though, you're totally right. Bright times ahead 🤩

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

      @@TechWithNader thanks for the reply brother , you are the most humble developer on you tube , we are with you and developer community need person like you , i feel happy to share your videos among my friends

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

      @@madfoodhunter Always such kind words, thank you so much! 😊

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

    What about For in loop and for of loops ??

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

      Hey Prasad! Good question! For if we covered in a previous video and it’s used on any iterables so we can use them anywhere. The for in loop is a bit dangerous and less used since (mainly for debugging) which is why I didn’t cover it - it includes everything in the prototypes. Generally you want to use Object.entries, Object.values, Object.keys, Object.getOwnPropertyNames etc to be more clear with the intentions. Hope that helps! 😊

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

    bro, your content is amazin, thanks for all of that, please if you can some day make the same w/node . You are amazing thanks for all of THIS .

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

      Thanks! I’ll be moving to the DOM then React then back to Node where we’ll build some fancy APIs 🧐🤓

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

      Also, I couldn’t come up with something funny enough to retort your funny 🤣 All THIS is so exciting, can’t wait!

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

      @@TechWithNader JJASJSAJSAJ i couldn't stop laugingh in all the video , there was 3 am, and i was laugingh about "this" keyword of Javascript, Again sorry for my english , and greets From Argentina , and thanks for all the content that you've already done, and all that you are going to do!, THIS is gonna be amazing

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

      @@soquark2648 Awesome haha! Love seeing your comments. This is absolutely going to be awesome 👏 🚀

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

    Hii bro Thank you making videos in so much Detail Thank you so much🙂
    in future can you please create some videos on (Call \ Apply \ Bind) Methods ??

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

      Hey Adil! I’ll be posting some exercises for these next since they definitely need more explanation and practice 😊 I hope it kind of made sense when I went through it in this video, haha!

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

    (this .anything () ) is the most confusing thing in my entire life

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

      Haha! Truth. Hopefully that feels less true after this video 😂

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

    Hi Nader, thanks for the lesson.
    At 46:35 on the vid you use an array into apply method and get both elements of the array printed.
    It is weird I just get the first one printed and I need to wrap everything inside a new array in order to have it all logged.
    Here is my code (I just changed names to have some fun) ´´´paul.friend2.greet.apply({name: "Pablo", age: 50}, [[11, 22, 33]]);´´´ This way I get [ 11, 22, 33 ].
    If I do use this line instead: ´´´paul.friend2.greet.apply({name: "Pablo", age: 50}, [11, 22, 33]);´´´ I only get 11 logged... any ideas?
    Not a major issue but I am curious about the fact that we get different results with the same lines of code ;)
    Have a good one!