JavaScript Metaprogramming - Dave Fancher - NDC London 2022

แชร์
ฝัง
  • เผยแพร่เมื่อ 1 ส.ค. 2022
  • Metadata, data about data, is everywhere. We seem to intrinsically understand that using data to further describe the data within our systems brings numerous benefits to taming complexity. It follows then that metaprogramming, programming that interacts with the program itself by inspecting or even manipulating its own code can bring similar benefits to our software.
    ES6 greatly expands upon JavaScript's existing metaprogramming capabilities with the Symbol, Reflect, and Proxy types. Through some practical examples we'll discuss the role each of these types play within JavaScript metaprogramming and see how they not only affect your code but even drive several modern language features.
    Check out more of our featured speakers and talks at
    www.ndcconferences.com
    ndclondon.com/
  • วิทยาศาสตร์และเทคโนโลยี

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

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

    This talk is amazing! Leaned a lot about JS and its internals.

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

    Source code from Dave’s github:
    github.com/davefancher/js-metaprogramming-old

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

    There’s nothing wrong with “delete” semantics of returning true when target is already deleted. It’s a valid point of view on this operation with idempotence in mind. It could have been implemented another way around, yes, but it would’ve meant the same kind of inconveniences but for another set of use cases. 9:57

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

      The is a problem with the delete returning true when the operation wasn't done is that, if it is already deleted and still returning true to me, it is lying to me. It is saying that, in some usecase which i'm deleting an property means that i'm expecting that property to exists. If not, then, there is something wrong before the delete and it may leads to future bugs. It should throw an error, not returning true to me.

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

      @@matheuss7348 I don’t remember the context of this comment anymore. But always: it depends