JavaScript the Hard Parts: Classes and Prototypes (OOP)

Поделиться
HTML-код
  • Опубликовано: 5 фев 2025
  • Join us at our live Javascript workshops every week: app.codesmith....
    During this workshop, East Coast Remote Immersive Lead Instructor Ryan McDaniel covers Object-Oriented Programming in JavaScript by going under the hood of OOP and the prototype chain.
    Ryan covers:
    4 approaches to object-oriented programming in JavaScript
    Prototype and the prototype chain
    Factories, constructors and classes
    ES5 and ES6 approaches
    Stay connected to our community!
    Codesmith: www.codesmith.io/
    Learn JavaScript for Free: csx.codesmith.io/
    Free Weekly Events & Workshops: app.codesmith....
    Follow us to stay updated!
    Facebook: / codesmithhq
    Instagram: / codesmithio
    Twitter: / codesmith_
    LinkedIn: / codesmith-llc
    TikTok: / codesmith.io
    #learntocode #javascript #programminglanguage #coding #softwareengineer #code #objectorientedprogramming

Комментарии • 8

  • @tshirtphilosophers
    @tshirtphilosophers Год назад +2

    I used to be so confused about "this". Your video was so helpful :)

    • @Codesmith
      @Codesmith  Год назад +1

      Happy to hear this was helpful for you!!

  • @welium123
    @welium123 Год назад +3

    Such a helpful video, Ryan is a great instructor!

  • @k0secha
    @k0secha Год назад +2

    Ryan is awesome! i watched two other ones and this is the one that made prototypes click. I like how he keeps people engaged by being funny af too. Oh and my eyes are so grateful that he uses notability in dark mode!

    • @Codesmith
      @Codesmith  Год назад +2

      Great shout - we should all try the notability dark mode

  • @rnarud
    @rnarud Год назад +1

    Awesome instructor ! Really enjoyed watching this Hard Parts session

  • @luciusrex
    @luciusrex Год назад +1

    this was great! thanks for sharing this. its what i needed. how do you ensure the methods in each new instance is kept (for use later) when you extract the new instances as JSON?

    • @Codesmith
      @Codesmith  Год назад +1

      Hey @luciusrex - glad to hear this was so helpful!! JSON is great for storing and transmitting data but can get very complicated when it comes to types/prototypes. It’s not currently possible to preserve a prototype when stringifying + parsing JS code, but you _could_ reconstruct one using a ‘reviver’ function - check out the MDN docs for more details! developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/JSON/parse