Evolution of Signals in JavaScript

Поділитися
Вставка
  • Опубліковано 28 лис 2024

КОМЕНТАРІ • 101

  • @edz8659
    @edz8659 Рік тому +136

    Chat to signals in ur area

    • @struggopuggo
      @struggopuggo Рік тому +6

      Blazingly hot signals I hope

    • @blackpurple9163
      @blackpurple9163 Рік тому

      ​@@struggopuggois there any glitch where I get 2 for the cost of 1??

  • @AwkworldStudios
    @AwkworldStudios Рік тому +82

    Can we just take a moment to appreciate Ryan. He is an amazing developer, great communicator, and still humble. I want to be like him when I grow up

  • @blue5659
    @blue5659 Рік тому +31

    JDSL had signals right from the beginning. Tom is a genious

  • @phoenix-tt
    @phoenix-tt Рік тому +35

    I am working on a Vue compiler implementation in Rust (as a side project).
    It's really cool to get a deep-dive of how reactivity works and how to keep VDOM-based approach performant.
    Another point the core team is working on is a pure signals implementation, very similar to what Solid is doing. Very excited the framework is not stagnant

    • @nixoncode
      @nixoncode Рік тому +1

      my team hasn't migrated to vue3 yet,
      good on you on the compiler 😊

    • @blue5659
      @blue5659 Рік тому +2

      Hello my friend. I am working on a fork of surma 's jsxx compiler for javascript, written in rust

  • @rsdyeahh
    @rsdyeahh Рік тому +8

    Just to note, Newton was the president of Royal Society, which conduct the investigations about the Calculus creation and decide that Newton was the true inventor. So, not really as a judge in court, but as the president of the entity which could decided.

  • @paxdriver
    @paxdriver Рік тому +3

    You know what came first though? Flash movieclips had their own timelines. They were containers with their own timelines (render cycles) and states. Flash 5 specifically had everything we call new today.

  • @leftyhero147
    @leftyhero147 Рік тому +8

    Tbh, I remember learning about signals in the electronics classes and also learning about it when I was learning Qt (C++). To me it felt very natural and effective as a solution both in electronics and UI Development. When I learned about Observables and Subscribers in JS I thought that it was the same thing but with some innovation that I wasn't aware of. Looking to this whole comeback of signals in JS makes me feel like the whole ecosystem was a massive MacGyverization all the time, and we just to ended up with the true solution (that already existed). I think that to me this whole story speaks loudly about how bad javascript is and makes me think that probably we wasted the last decades trying to work around the limitations of it.

    • @SimonBuchanNz
      @SimonBuchanNz Рік тому +3

      It's pretty misleading to compare Qt signals and slots to eg SolidJS: there's not really much in common other than the name and that they cause UI updates. Qt signals are basically just JavaScript events (which aren't really like Qt's events, confusingly), something it's had since day one in 1995 (the same year as the first Qt!)
      The reason people are excited about signals in JS now isn't that you can run code when something changes, it's that the implementing runtime makes it trivial to define and use them, and to create derived state that is also trivial to use, and there's no need to connect and disconnect, it's all implicit where is being used, and you don't need to worry about reentry or dependency loops because the updates are always scheduled rather than synchronous.
      Basically the entire need for anything other than the obviously needed "show this" and "do that" code just vanishes into the runtime.

    • @chaos_monster
      @chaos_monster Рік тому

      Qt Signal/Slot Pattern was also what I was thinking of first but it is not the same

    • @christianm4906
      @christianm4906 10 місяців тому +1

      Qt Signals and Slots are just another implementation of the Observer design pattern, something that has existed from the beginning and has proven to work well. I don't understand why the web industry didn't favor this pattern in all its UI frameworks and libraries. It feels like a complete waste of time having to spend so many hours dealing with the painful React.js rendering approach, only to realize that it really sucks.

  • @aleksazivanovic1539
    @aleksazivanovic1539 Рік тому +13

    The thing with react not wanting to change it’s mental model is that in their current mental model UI is function of state and therefore re-rendering is mandatory and you cannot simply introduce signals without changing what is considered as fundamentals of react.

    • @aleksazivanovic1539
      @aleksazivanovic1539 Рік тому

      Even though I like signal and think of it as a better approach for debugging and performance

    • @heroe1486
      @heroe1486 Рік тому +3

      ​​​@@aleksazivanovic1539 While they have no problem introducing oddities like RSC or have their core devs say that "if you use React to build apps you should use framework" although react "fundamentals" have always been that it's an unopinionated library that only does few things.
      And also had no problem switching the entire ecosystem to hooks few years ago.
      Doesn't seem like stability and strong principles are their priorities

    • @aleksazivanovic1539
      @aleksazivanovic1539 Рік тому +1

      @@heroe1486 Well, must I must agree with what you said😅

    • @usercl3ev2pt1b
      @usercl3ev2pt1b Рік тому

      Rerender everything when a single node is changed is wrong for ui dev. Ui is not at all about state management, also motion, gesture, animation so 'rerender everything' simply wont work

  • @andythedishwasher1117
    @andythedishwasher1117 Рік тому +12

    This interpretation of the signals concept is the reason Solid JS was the only JS framework in which I succeeded at creating an editable JSON tree on the front end. Maybe I just suck at JS, but the state management issues felt pretty insurmountable without getters and setters.

  • @mfpears
    @mfpears Рік тому +1

    23:30 Observables aren't supposed to abstract away reactivity. They're supposed to make you write your code less like a pile of garbage. That's a good "leak"

  • @MichaelLazarski
    @MichaelLazarski Рік тому +4

    Fun fact: I wrote my Bachelor Thesis about Meteor. Still one of the best frameworks which I don't use at all.

  • @cmelgarejo
    @cmelgarejo Рік тому +1

    18:00 * hides account with over 100k karma, walks to the back, whistling *

  • @jaysistar2711
    @jaysistar2711 Рік тому +2

    Meteor isn't hard to reason about, but there's not any isolating documentation. (Meaning docs that just explain 1 part in detail without other parts.) SolidJS signals and Leptos signals do about the same thing, but they added a "collection" concept which has a MongoDB like interface (on the client side).

  • @Ring0--
    @Ring0-- Рік тому +9

    Godamnit Prime. LET ME SLEEP!

  • @andythedishwasher1117
    @andythedishwasher1117 Рік тому +2

    I feel you on being a tool guy. I enjoy making stuff easier and faster, but I don't care so much making it pretty unless that serves the first two parameters. Trying to get into building no-code frameworks for front ends so that when we need front ends in our world of tool builders, we can just toss them together in a visual framework stocked with handles for the kind of internal tools that are being built frequently these days. Less consumer oriented, more engineer oriented.

  • @danielvaughn4551
    @danielvaughn4551 Рік тому +5

    I'm also obsessed with tools but I also love the frontend. I'm creating a website builder that's primarily keyboard-focused. It's like vim for web designers lol.

    • @Milky____
      @Milky____ Рік тому +1

      That sounds fking amazing let us know the name would love to check it out one day!

    • @danielvaughn4551
      @danielvaughn4551 Рік тому +1

      @@Milky____ will do!

  • @ShadowKestrel
    @ShadowKestrel Рік тому +3

    Something more important to look at is the Evolution of Signals in JDSL.
    To see how it has changed over time, we'll look through the SVN... oh no, I broke JDSL. Tom is too much of a genius for me 😔

  • @derschutz4737
    @derschutz4737 Рік тому +3

    Performance is not an advantage signals inherently have over a VDOM. A VDOM can be just as performant as signals (hence why dioxus is as fast as leptos).

  • @abuk95
    @abuk95 Рік тому +5

    How does this front-end Signals concept compare to Qt's signals? Is it the same thing? How do they differ?

  • @dmitriylevy7865
    @dmitriylevy7865 Рік тому +1

    "you a call function, the function poops out the value, then changes it in the html" 19:48
    "you want more details pooping out the value? go look at SolidJs" 20:40

  • @mrbigberd
    @mrbigberd 8 місяців тому

    Elm went ALL the way down this rabbit hole. It was based on Evan's FRP thesis ideas about signals. Even when the whole language was designed around the concept, it wound up being dropped because of the issues around making them ergonomic, safe, and scalable. Elm ultimately dropped FRP.

  • @simonfarre4907
    @simonfarre4907 Рік тому +1

    I also love tool building. It's why I contribute to projects like GDB, RR etc. It's fun. Also, the guys who either are maintainers (GDB) and authors (RR) are just a vast ocean of expertise. They make me feel dumb, all the time (that's NOT their intention though), but boy you learn so much from the know how.

  • @ThePandaGuitar
    @ThePandaGuitar Рік тому +1

    Experimented with SolidJS last year and I was impressed.

  • @laughingvampire7555
    @laughingvampire7555 8 місяців тому

    those who thought on making bi-directional data binding never made their own mechanical keyboards or they never understood why you need to add diodes to a mechanical keyboard

  • @fuzzy-02
    @fuzzy-02 Рік тому +2

    Im an undergraduate and I have no idea what Prime is saying most of the time, but damn do I have fun watching him.
    And I also feel smarter UwU

  • @hamm8934
    @hamm8934 Рік тому +4

    Once I went Vue, I never left. Even svelte doesn’t feel too much easier than Vue. For me, Vue is that perfect balance.
    Also, being able to use Vue without a build step really is such an asset for integration and updating legacy stuff.

    • @shrin210
      @shrin210 Рік тому +1

      Whatever we chose we got comfortable with it
      For me it was React

  • @christianm4906
    @christianm4906 10 місяців тому

    Implementations of the Observer design pattern have existed since the beginning and have proven to work well while maintaining simplicity. A prime example is the Qt/C++ framework's signals/slots mechanism, which enables communication between classes without needing to know anything about their implementation. This is a true separation of concerns in practice. I don't understand why the web industry didn't favour this pattern in all its UI frameworks and libraries. It feels like a complete waste of time to spend so many hours dealing with the painful React.js rendering approach, only to realise that it really sucks. To clarify, I am not comparing SolidJS with Qt here, but rather expressing my preference for the simplicity and effectiveness of the Observer pattern as implemented in systems like Qt.

  • @quantum_dongle
    @quantum_dongle Рік тому +1

    I use Meteor in prod... It's theoretically so good, but the actual usage of it quickly becomes spaghetti

  • @andythedishwasher1117
    @andythedishwasher1117 Рік тому +2

    I have to say SolidJS was pretty decidedly my best experience in the JS world, but I still don't have great feelings about the JS world.

  • @abc123evoturbobonker
    @abc123evoturbobonker Рік тому +3

    Lol, YT recommends Bill Burr since I started watching you

  • @jamiebowers7484
    @jamiebowers7484 Рік тому +1

    Plus one for Vue, especially version 3. I'd love to watch a "reaction video" of you trying Vue.

  • @khhnator
    @khhnator Рік тому +2

    as someone who doesn't do webdev... i have no idea whats is being spoken about... is signals just like events?

  • @Ring0--
    @Ring0-- Рік тому +4

    Bill Burr has his moments. But they can sound similar.

  • @huang47tw
    @huang47tw 4 місяці тому

    I also need to take a deep breath when seeing both sweetjs + rxjs

  • @qm3ster
    @qm3ster Рік тому +1

    Does something already exist to attach RxJS (good for organizing my event/signal logic) to Solid.js signals for rendering?

  • @Yay295
    @Yay295 Рік тому

    So it's events, but with a library abstraction tacked on top.

  • @lukehightower4198
    @lukehightower4198 Рік тому

    And Ders' from Workaholics! You funny as hell mang

  • @gertrude1310
    @gertrude1310 Рік тому

    You guys are talking like those frameworks invented the prefect data binding, yet almost a decade earlier the ActionScript Flex framework already had all this perfectly tuned. It feels like React, MobX etc are just going to end up converging to what was once....

  • @naranyala_dev
    @naranyala_dev Рік тому

    great article, prime movement

  • @projectodemayhem
    @projectodemayhem Рік тому

    "...JavaScript isn't the best language..."
    - Ryan Carniato

  • @ddomingo
    @ddomingo Рік тому +1

    Personally, I saw react and thought “I still like jQuery more”. 2013 was a chaotic year for the frontend world, I didn’t get why any of these new frameworks/libraries were better than just plain old jQuery. I absolutely hated AngularJS. RxJS was very impressive, but it took me years to understand.

    • @ThePrimeTimeagen
      @ThePrimeTimeagen  Рік тому

      hah, rxjs... dang
      i loved that one until i hated that one

  • @medilies
    @medilies Рік тому +1

    West World is top-notch, every seasonh...

  • @PixelOutlaw
    @PixelOutlaw Рік тому +1

    There's probably a tasteful balance but I think they're getting pretty gross. Everything's starting to look like a Perl one liner.

  • @laughingvampire7555
    @laughingvampire7555 8 місяців тому

    Elm has had the reactivity with compiler long before all those people, long before Svelte, but your insistence on having familiar syntax makes lose of the best tools.

  • @Ring0--
    @Ring0-- Рік тому

    2 good seasons Yoshii

  • @vishaldinesh
    @vishaldinesh Рік тому

    That was me I'm the greek guy hey prime, and people do sometimes refer to me as The Greek God

  • @_diversable_
    @_diversable_ Рік тому +2

    If you're interested in building tools for developers... what do you think dev tools could / might look like in 3D environments like the Apple Vision Pro ??

  • @jvoyager1
    @jvoyager1 Рік тому

    Qt/PyQt, has been using signals/slots as well

    • @W1ngSMC
      @W1ngSMC Рік тому

      It's not the same thing.

  • @codedusting
    @codedusting Рік тому +1

    Madhava of Kerela School of Mathematics, India. 200 years before either Newton or Leibneiz. Search for him. Then search for how Jesuit Priests stole that knowledge and brought it to the West. How it connects with Newton.

    • @ea_naseer
      @ea_naseer Рік тому

      Greeks with Method of Exhaustion (integral calculus): 🍹🍹

    • @notlessgrossman163
      @notlessgrossman163 Рік тому

      Babylon had it before all that

  • @Ring0--
    @Ring0-- Рік тому

    I need either SD coffee or SD Xanax.

  • @mfpears
    @mfpears Рік тому

    1:05 Imperative spaghetti is worse

  • @legitjimmyjaylight8409
    @legitjimmyjaylight8409 Рік тому

    You mean like signals and slots from QT?

  • @andythedishwasher1117
    @andythedishwasher1117 Рік тому +1

    I want to see Ryan write a front end framework in Mojo! That would totally be the future!

  • @k98killer
    @k98killer Рік тому

    I believe jQuery is properly pronounced "jackery". /s

  • @naranyala_dev
    @naranyala_dev Рік тому

    more article from hackernews!!!

  • @fredguth1315
    @fredguth1315 Рік тому

    Rodriguez? Leibniz?

  • @Yutaro-Yoshii
    @Yutaro-Yoshii Рік тому

    5:45 I would have appreciated a west world spoiler alert

    • @Yutaro-Yoshii
      @Yutaro-Yoshii Рік тому

      @@mattmurphy7030 now you got a like on your comment. I'm mad😂😂😂

  • @danylo.s
    @danylo.s Рік тому

    Why he does this "rwwrr" thing? What does it even mean?..

    • @1Caja
      @1Caja Рік тому +3

      You aren't ready to know yet

    • @EIsenah
      @EIsenah Рік тому

      You don't find it sexy?

    • @TheNewton
      @TheNewton Рік тому

      it's a joke/satire implying what was just said can have a sexy innuendo to it that would appeal to the humor a 13 year old would have but he has a 18+ audience that should be more mentally mature, but aren't.
      It's like waggling your eyebrows and saying "that's what she said" to any thing even if it banal😏.

  • @hakuna_matata_hakuna
    @hakuna_matata_hakuna Рік тому

    devto markdown is doodoo

  • @mvargasmoran
    @mvargasmoran Місяць тому

    impossible to watch...

  • @TheC3lso
    @TheC3lso Рік тому +3

    first (who cares in the end haha)

    • @TheC3lso
      @TheC3lso Рік тому +1

      @@mattmurphy7030 Because why not? Nobody needs to care, it was cool to see the possibility and then doing it for the fun!

    • @TheC3lso
      @TheC3lso Рік тому

      Well, you will get over it anyway

    • @codestuff782
      @codestuff782 Рік тому +1

      I also care bro, go for it!

  • @sandworm9528
    @sandworm9528 Рік тому

    First!
    Ok people, if you see this comment and there's less than ten comments, you should also comment "first". As the actual first comment i officially give you permission

  • @edz8659
    @edz8659 Рік тому

    First

  • @donnikitosCom
    @donnikitosCom Рік тому

    I've been experimenting with signals as too. What do you guys think about @mutablejs/core?