React 19 Is FINALLY Here

Поделиться
HTML-код
  • Опубликовано: 24 апр 2024
  • What a release. This took forever. Server Components, actions, and more, all accessible to everyone without installing a dang canary.
    SOURCES
    react.dev/blog/2024/04/25/rea...
    Check out my Twitch, Twitter, Discord more at t3.gg
  • НаукаНаука

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

  • @joe-robin
    @joe-robin 3 месяца назад +175

    I think he hadn't slept in while

  • @dbizzle4
    @dbizzle4 3 месяца назад +230

    Really disappointed they're not coming out with the useDunningKrugarEffect hook

    • @naughtiousmaximus7853
      @naughtiousmaximus7853 3 месяца назад

      They should make a useVue or useSvelte hook that automatically rewrites your app in respective frameworks.

    • @dellavita3463
      @dellavita3463 3 месяца назад +1

      What is this mean ?
      Can somebody explain?
      Thank you

    • @shinmini99
      @shinmini99 3 месяца назад

      The Dunning-Kruger effect is a cognitive bias that occurs when someone overestimates their knowledge or abilities in a particular area. The term was coined in 1999 by Cornell University psychologists David Dunning and Justin Kruger.

    • @XavierGoncalves89
      @XavierGoncalves89 3 месяца назад +2

      I also need some context

    • @artieschmidt3039
      @artieschmidt3039 3 месяца назад +2

      @@dellavita3463 maybe a pun on the Dunning Krugar Effect?

  • @Jessyco
    @Jessyco 3 месяца назад +11

    Should have the React team add that detail about "use server" and "use client" such a simple explanation that brings clarity, thank you!

  • @imbaedin
    @imbaedin 3 месяца назад +31

    The way that the form acts as a context provider is the same way react-hook-form operates. It's nice when building complex reusable form inputs. Essentially the consumer can treat it as an uncontrolled input.

    • @tsanyqudsi
      @tsanyqudsi 3 месяца назад +1

      It's going to be interesting to see how reacthookform going to pivot after this.

    • @imbaedin
      @imbaedin 3 месяца назад +1

      @@tsanyqudsi react hook form has native support for zod. I think the use cases are different enough to both be used even within the same codebase.

    • @AlianzaGaming
      @AlianzaGaming 3 месяца назад

      Yes you can do this

    • @tsanyqudsi
      @tsanyqudsi 3 месяца назад

      @@imbaedin true. But zod might build for this too.

    • @seannewell397
      @seannewell397 3 месяца назад

      It'll be excellent if they swap some intervals out for these if it detects a react 19 app. No idea how compatible it is, i assume they have reducers internally and couldn't simplify. But maybe not.

  • @keithjohnson6510
    @keithjohnson6510 3 месяца назад +7

    The array destructuring assignment point, totally 100% agree. I'm constantly using object destructuring because it creates self documenting code from the caller, you also get great code completion.
    But there is another really good reason to use object destructuring instead of array, in my tests array destructuring is slower than object destructuring.

  • @VaurionX
    @VaurionX 3 месяца назад +4

    I’m really interested to test this out once it’s more stable. Very exciting that some of the stuff we’ve had in NextJS is coming to React

  • @martoxdlol
    @martoxdlol 3 месяца назад +1

    The "use client" and "use server" explanation was excellent! I will be using it

  • @returntozerotv
    @returntozerotv 3 месяца назад +2

    Do you think the improvement about stylesheet loading make it possible to use css-in-js in streaming/RSC?

  • @rafaeldeleon3386
    @rafaeldeleon3386 3 месяца назад +57

    "...but forms are full of weird implicit b.s., so I think it aligns with that".
    Yup, forms come with baggage, lets add to the baggage.

  • @jackdanielson1997
    @jackdanielson1997 3 месяца назад +288

    Oh yay, 5 new hooks I never wanted. So excited

    • @DigitalPlumbing
      @DigitalPlumbing 3 месяца назад +5

      rofl, you put words to this lacklustre roadmap/release

    • @Eckster
      @Eckster 3 месяца назад +36

      `use` solves a lot of the issues with useEffect and async work, so I'm pretty happy about that one

    • @Sindoku
      @Sindoku 3 месяца назад +14

      They aren’t for you. I’m assuming you’re an application developer. It’s for library authors and to make their lives better.

    • @Alkyen
      @Alkyen 3 месяца назад +8

      @@Sindoku which hooks aren't for devs? Yes, they are in beta still so this is why only library authors are advised to play around with them but when React 19 is stable most of those hooks have uses in regular application code.

    • @TypingHazard
      @TypingHazard 3 месяца назад +15

      I heard that in React 20 if you don't use every Hook that React provides in your app it won't compile. Sadge

  • @ChrysusTV
    @ChrysusTV 3 месяца назад +1

    I'm guessing at 10:23 you're referring to mutation scopes for TS Query? Had to dig a bit to find it. Looks like the feature was released only a few days ago so not sure if that's what you're referring to in the video... Seems like a neat idea but probably clunky in practice with a limited use case. For example, I rarely work with forms but rather with editable tables with many rows. The scope can only be set when calling useMutation rather than when calling mutate. Of course you can't conditionally have useMutation so it seems like it would be impossible to limit the scope to a row ID or a row/column pair per call. Instead I'd have to scope it to the entire table so that all mutations on the table run sequentially, even if for entirely different records. In my mind, a form is something you type into and submit once, then wait for validation. It seems strange a system would allow changing and resubmitting a form while it is already submitting (thus running into the race you mentioned). On the other hand, a table is definitely a place where you're constantly moving around and typing into various columns/rows multiple times, yet it looks like granular mutation scope couldn't be supported in such an ideal use case.
    Of course, I could rebuild the entire table system from scratch (using Mantine on top of TanStack Table currently) to make a custom Row component where each Row has its own mutation scoped to the Row's record -- but definitely not doing that either :)
    Also why is the sidebar for all TanStack docs so incredibly slow/laggy? Not enjoyable at all to work with 😂
    Edit: Nice, there is an ongoing discussion about this limitation :) github.com/TanStack/query/discussions/7126#discussioncomment-8815577

  • @guseynismayylov1945
    @guseynismayylov1945 3 месяца назад

    Why do I need to load my css by React, if I can preload them in tag via .

  • @yiannis_p
    @yiannis_p 3 месяца назад +22

    This video showcases among other things the very edge of the term acceptable when it comes to puns. Amazing video and super stoked for react 19!

  • @mark1395711
    @mark1395711 3 месяца назад

    How would the submit not the first item of the useActionState returned array
    You will 100% need the submit, but not error(for example error is catched in the API client level and automatically shows a error popup)
    Then you'll have the first arg unused

  • @cintron3d
    @cintron3d 3 месяца назад +1

    Very cool stuff, only con is the library just keeps getting bigger. I love SolidJS for the small bundle size. But some of those features like script tags look really useful.

  • @SkillR1
    @SkillR1 3 месяца назад +1

    for useActionState a better generic naming is `{ state, dispatch, isRunning }`
    error is only related to the current example

  • @helleye311
    @helleye311 3 месяца назад +1

    The only thing I dislike about all this is the form data. I'll probably end up making a proxy object that's typescript-cast as T.
    I've also been a huge fan of having some components have custom value/onChange that can accept anything, not just strings. I've made database driven dropdowns with those that give back the full object instead of just the id or whatever, helped in some places. Unfortuntely doesn't seem doable with form data. Not to mention multi-item selects or any other fancy thing like that.
    I get that form data is the web standard, but I really wish we'd migrate to json/objects already. Same with the UrlSearchParams.

  • @Sindoku
    @Sindoku 3 месяца назад +4

    I think I’ll stick to using react query for async data management and react-hook-form for forms. They play together nicely.

    • @MARKOTHEDEV
      @MARKOTHEDEV 3 месяца назад

      love u for saying this lol. they play tooooo nice

  • @aurorasofie
    @aurorasofie 3 месяца назад

    I’m actively using the use() hook for the promise-part in my project. It’s super use()ful. For example, I have a server component fetching multiple pieces of data. And it contains multiple client components that need this data. I can now call const data = getData, (and I have multiple of these) and pass these promises down, then suspend the client components individually. If I didn’t do this, the whole server component would have to suspend for the await to finish.

  • @ChimbzZ
    @ChimbzZ 3 месяца назад

    15:43 where did they define updatedName? Or is it a typo?

  • @dbizzle4
    @dbizzle4 3 месяца назад +25

    As a small language bot I already switched to SolidJS.

    • @AveN7ers
      @AveN7ers 3 месяца назад +6

      I'd love to see Solid take over man but companies are slow to change. A shit load of them are still using jayQwellin

    • @adamkarafyllidis9264
      @adamkarafyllidis9264 3 месяца назад

      I would love to also switch to SolidJS but there is also react native which holds me to react..

    • @Quephara
      @Quephara 3 месяца назад

      ​@@adamkarafyllidis9264is this compatible with nativescript?
      Like, I know svelte is

  • @NR1612
    @NR1612 3 месяца назад +31

    These bot accounts are crazy. Anyway, excited to use some of these hooks and maybe get rid of bloated state managers for my smaller projects.

    • @guseynismayylov1945
      @guseynismayylov1945 3 месяца назад

      just use EHTML dude

    • @SandraWantsCoke
      @SandraWantsCoke 3 месяца назад

      bot accounts?

    • @NR1612
      @NR1612 3 месяца назад +1

      @@SandraWantsCoke They've been removed since I commented. A lot of sexually suggestive profile pictures.

  • @olivierromanetti9651
    @olivierromanetti9651 3 месяца назад +1

    What can I say ? thank you for this tutorial. It took me 3 days to do it and figure it out ha ha. It's very dense, and therefore very stimulating. So thank you again Théo! great content. I'm going to bed less stupid

  • @tinrab
    @tinrab 3 месяца назад

    The new Form utils are good for the ecosystem, I guess. Frameworks can agree on how to do forms. But, my go-to is still react-query and hook-form or tanstack form.

  • @3dxspx703
    @3dxspx703 3 месяца назад +5

    Finally. Svelte is the goat.

  • @PhilipAlexanderHassialis
    @PhilipAlexanderHassialis 3 месяца назад

    Interesting stuff, leaning heavily though into the SSR and RSC side of things. I wonder if there will be a time when we can declare a client only functional component as an async function and then have the client exclusively await the whole thing inside a suspense boundary. Now, that, that would be neat.

    • @davien001
      @davien001 3 месяца назад

      You can use the use() hook for API call then surround the component fetching data with a Suspense component with a fallback loading state.

  • @NopeNopeNope9124
    @NopeNopeNope9124 3 месяца назад +2

    Yeah well React 20 is gonna blow your mind

  • @NaCl-e
    @NaCl-e 3 месяца назад

    There are many of your takes I don't agree with as a developer, but I really like hearing your points as well. Maybe my viewpoint will change to be similar to yours somewhere down the line. In other words, great job outlining the changes, keep on doing what you are doing.

  • @AdeelEjaz
    @AdeelEjaz 3 месяца назад +2

    "I have feelings, I have a lot of feelings..." Yes, Theo, don't we all.... don't we all...

  • @NishadGurav
    @NishadGurav 3 месяца назад +2

    Glad to see you're a fellow "Outer Wilds" fan!

    • @t3dotgg
      @t3dotgg  3 месяца назад +1

      Keep an eye out for me in the credits ;)

  • @dukeselwood
    @dukeselwood 3 месяца назад +25

    Did I miss it, or did they not mention the new compiler?

    • @potetotes
      @potetotes 3 месяца назад +6

      React Compiler is not shipping in React 19-but it is coming to oss sooner than you expect. the fundamentals are good (imo) but getting it out sooner comes at a tradeoff of not being fully feature complete. lower your expectations for the release but raise them for when

    • @lubovalkov7378
      @lubovalkov7378 3 месяца назад

      Yes, I was wondering this as well.. it's happening after it comes out of beta or at a later point? Does anyone know?

    • @potetotes
      @potetotes 3 месяца назад

      @@lubovalkov7378 no promises on when, but pretty soon is what i can tell you

  • @zhexymusic
    @zhexymusic 3 месяца назад +12

    You seem pretty calm on the video. Why are you making strange faces on thumbnails? 👀

    • @aisdjsiasiodjisoajd7698
      @aisdjsiasiodjisoajd7698 3 месяца назад +1

      if you clicked on the video and left this comment it’s working bud

    • @zhexymusic
      @zhexymusic 3 месяца назад +4

      @@aisdjsiasiodjisoajd7698 It is an interesting topic, first of all. I've learned to read the title of the video before seeing the thumbnail. But Theo is making too odd faces.

    • @whoman7930
      @whoman7930 3 месяца назад +5

      @@zhexymusic yes I hate that too.

    • @inakiarias7465
      @inakiarias7465 3 месяца назад

      @@whoman7930 Don't hate the player

  • @Dom-zy1qy
    @Dom-zy1qy 3 месяца назад

    Did you record this early in the morning? You seem a little bit more chill in this video than usual. Not complaining, just a different vibe.

  • @megamind452
    @megamind452 3 месяца назад

    But where is the "server" actually located in the React server component?

  • @owenwexler7214
    @owenwexler7214 3 месяца назад

    35:03
    That's definitely going to be fixed by the end of the next Hacktoberfest if not before.

  • @thegrumpydeveloper
    @thegrumpydeveloper 3 месяца назад

    If they ship with ordered props definitely going to wrap that with a named prop version of it.

  • @zuma206
    @zuma206 3 месяца назад

    The reason they didn't show suspense for use, is because you technically don't need it. The initial react render is now async, and will just be delayed by any use calls. Then if you were to wrap every state change in a transition, the transition can also wait out the use calls. It's only for non-transition state changes that you actually NEED a suspense.

  • @fcnealvillangca7943
    @fcnealvillangca7943 3 месяца назад

    I will wait for tutorials and people testing it before I go back to make project with react

  • @tusharsharma4972
    @tusharsharma4972 3 месяца назад

    to select second element you don't have to put an "_" underscore as the first item, you can just do const [,second] = ["first", "second"] and it would pick up the second element

  • @yamyam263
    @yamyam263 3 месяца назад

    Any video by casual apparel Theo is automatically a banger ❤

  • @Fanaro
    @Fanaro 3 месяца назад +1

    React should create a troll hook called `useCase`.

  • @upsxace
    @upsxace 3 месяца назад

    Woah, i'm pleasently surprised by the new stuff. React is actually taking care of multiple scary problems that have been a nightmare for years. A bit late, but better late than never.
    Hopefully they keep that direction in the next following yeas.

  • @elfensky
    @elfensky 3 месяца назад

    please explain why the [error, submit, isPending] order matters, doesn't it simply get them by name from the ActionState, like a useContext?

    • @TypingHazard
      @TypingHazard 3 месяца назад +2

      You're not accessing key-value pairs like myObject[error], you're destructuring an array. So you do have to Just Know what the values at a given index in the array actually do.
      Like when you do something like "const [foo, setFoo] = useState('');" useState is just returning an array with some value and some state setter, they aren't named and it's up to the developer to know that index 0 is the value and index 1 is the setter

    • @elfensky
      @elfensky 3 месяца назад

      @@TypingHazard :O

  • @user-ik7rp8qz5g
    @user-ik7rp8qz5g 3 месяца назад +1

    What about compiler? When it will be available?

    • @potetotes
      @potetotes 3 месяца назад +1

      React Compiler is not shipping in React 19-but it is coming to oss sooner than you expect. the fundamentals are good (imo) but getting it out sooner comes at a tradeoff of not being fully feature complete. lower your expectations for the release but raise them for when

  • @DavidInoa
    @DavidInoa 3 месяца назад +4

    17:02 You're mistaken regarding the need of a wrapper
    You can directly return the result of the .map() function inside a React component's render method or another JSX expression.
    export default function App() {
    const greeting = ["Hello", "World"];
    return greeting.map((value) => {value});
    }
    // Returns:
    // Hello
    // World
    I would link you to a codesandbox, but my comment will get removed. Try it yourself

    • @adamviktora6440
      @adamviktora6440 3 месяца назад

      Yes, array of JSXElements is a valid ReactNode, and can be used just like a fragment

    • @Jamiered18
      @Jamiered18 3 месяца назад +1

      Don't forget the keys though

  • @Frexuz
    @Frexuz 3 месяца назад

    "Just load a script tag" (video player example) definitely won't work for external ones if ur using strict CSP policies. Just something to think about :)

  • @parifuture
    @parifuture 3 месяца назад

    Oh Theo…a tee? Hope all is well

  • @Lemmy4555
    @Lemmy4555 3 месяца назад +5

    Svelte beta: at first i did not like it but these runes makes sense
    React beta: not sure what should i do with these hooks

  • @ankitkumarjat9886
    @ankitkumarjat9886 3 месяца назад +8

    So in simple words react has its own react-query implementation 😂😂😂

  • @Fanaro
    @Fanaro 3 месяца назад

    Theo, no need to rush with content. Take some rest.

  • @abdoufma
    @abdoufma 3 месяца назад

    Wait, wasn't the react compiler part of the 19.0 release? 🤔

  • @Paul_Marek
    @Paul_Marek 3 месяца назад

    I’m new. I didn’t understand a word he said for the whole video. But I’m learning.

  • @alexbennett5647
    @alexbennett5647 3 месяца назад

    React 19: We leverage the bundler now!

  • @garcipat
    @garcipat 3 месяца назад

    What happened to the compiler stuff?

  • @zuxcode
    @zuxcode 3 месяца назад

    23:44 I feel bad for the forward ref 😂

  • @PascalVos
    @PascalVos 3 месяца назад

    custom element support finally!

  • @gageracer
    @gageracer 3 месяца назад

    Bro I hope you are okay, you sound tired and different from the other vids. That is all fine, just got worried all of a sudden in this vid.

  • @MrSofazocker
    @MrSofazocker 3 месяца назад

    Arrays consisting of not even multiple datatypes, but error, data, and hooks is batshit insane.

  • @Dimonina
    @Dimonina 3 месяца назад

    Time flies, but nothing changes. All the frameworks introduce features which solve the problems that could be solved with rxjs out of the box many years ago.

  • @huntinator77
    @huntinator77 3 месяца назад

    I just... I don't like implicit stuff. Maybe that's just me, but this is why I avoid using already. I'd rather keep making my own little form hook or using react hook form, where I or other devs can always view the implementation. It's just one less thing that you have to learn about the framework to be able to use it.
    Like an input with type=submit? There's no way you could ever figure that out without being told by a tutorial or another dev or the mdn docs. But a button with onclick calling a function that you implemented 20 lines later? Easy, straightforward, self-documenting.
    I'm sure there will be plenty of people who like the new form extensions and will use them all the time, but I don't think these are for me

  • @Matt23488
    @Matt23488 3 месяца назад

    9:50 - You don't have to discard tuple members with an underscore, you can simply omit the name entirely and just put a comma to denote you are skipping an element. However I don't think that actually addresses your concerns all that well. Personally I really like the tuple returns because of naming the values while writing half as much code to do so compared to renaming destructured object keys. I don't think having to remember the order is as big a deal as you are making it out to be. Perhaps with vanilla JS I could potentially see issues arising from that, but if you're using TypeScript this will be a non-issue entirely since they all have different types.

    • @keithjohnson6510
      @keithjohnson6510 3 месяца назад

      So -> `const [name, setName] = useState('')` is good, but -> `const {get: name, set: setName} = useState('')` is too much typing.? Not really twice as much code, but I can give you good reason for the second version, it's faster..

  • @drewhjava
    @drewhjava 3 месяца назад +1

    Ready for the new Sima version

    • @user-kf7vy5yu2v
      @user-kf7vy5yu2v 3 месяца назад +1

      I think ill wait for Masim personally

    • @LaughingRam
      @LaughingRam 3 месяца назад

      SIMA and then Ligma, in that order.

  • @andersbodin1551
    @andersbodin1551 3 месяца назад

    I hope react 19 will make class components cool again

  • @anwiseru9064
    @anwiseru9064 3 месяца назад

    "i could even see a library that does the..."
    scariest javascript developer words

  • @bomberfish77
    @bomberfish77 3 месяца назад +1

    16:29 Pretty sure React copied this from a smaller framework called DreamlandJS

  • @emmanueleboh868
    @emmanueleboh868 3 месяца назад

    Looks promising, I could say we now have an opinionated way for writing forms in React

  • @academai11
    @academai11 3 месяца назад

    web is like a wine, its aging but not fine

  • @igots
    @igots 3 месяца назад

    The title and meta tags stuff is going to cause more grief than people realize.

  • @paxdriver
    @paxdriver 3 месяца назад

    Dude thanks for the vid. You look like you just gave birth at the office lol I feel bad you work so hard.
    Legit question though, how is an event or signal with usememo, or a consolidation function, considered "a bunch of other code" to accomplish the same thing as use transition? It never really seemed like a lot to me. Even arrow functions seemed pointless shorthand unless binding "this" is part of the function (in which case arrow functions are a godsend and why would you use anything else?)

  • @RuySenpai
    @RuySenpai 3 месяца назад

    0.0001 seconds into the video "Is that an Outer wilds shirt?"

  • @coolemur976
    @coolemur976 3 месяца назад

    9:30 This should be basic knowledge that named prop object is better than array... How they even thought of using array for this.

  • @kashnigahbaruda
    @kashnigahbaruda 3 месяца назад

    Shocking how many broken code examples are in that blog.

  • @user-tb4ig7qh9b
    @user-tb4ig7qh9b 3 месяца назад

    The reason is performance v8 could handle array better than object

  • @jon1867
    @jon1867 3 месяца назад

    Meanwhile, the new TS Beta release looks FIRE

  • @creaky2436
    @creaky2436 3 месяца назад +1

    Still not a fan of useOptimistic. You can just use simple state for all of that. You can even write your own hook that does it, or have some toast that pops up if the data that was trying to be updated failed or something.

  • @fartune9646
    @fartune9646 Месяц назад

    7:54 array does not have any advantages over object in case of using 2 and more actions

  • @user-ho4yz2fl3i
    @user-ho4yz2fl3i 3 месяца назад

    At first glance these hooks are somewhat in the direction of react-query

  • @seannewell397
    @seannewell397 3 месяца назад

    Using context for form state kinda sucks imo. A signal or a composable & selectable stats primitive (zustand / jotai) feels much better to prevent excessive re-renders.

  • @calo4626
    @calo4626 3 месяца назад

    I was taught that hooks should never have if-else conditions before it. I hate to use `use`.

  • @zapphoddbubbahbrox5681
    @zapphoddbubbahbrox5681 3 месяца назад

    when i read this earlier, i didn't come so hard because HTMX (ceo/same)

  • @hazembenbz
    @hazembenbz 3 месяца назад

    After breaking half my dependencies upgrading to react18, I guess it is time to break the other half 😂

  • @nothingtoseehere5760
    @nothingtoseehere5760 3 месяца назад

    I'm learning React, should I bother with 18? It seems like it includes so many redundant things...

  • @ScottMaday
    @ScottMaday 3 месяца назад

    8:00 L take, I find it incredibly rare to accidentally swap the order of destructured arrays. And if I do, it's fairly obvious since I won't hear the end of it from typescript until its fixed and will be caught well before it makes it to code review. It's not worth so much extra verbosity to type using the object destructured (which I believe was a big complaint from Theo when reviewing Panda CSS)

  • @stepans2167
    @stepans2167 3 месяца назад +1

    9:45 you don't have to put the underscore there

    • @velifurkanturkoglu1387
      @velifurkanturkoglu1387 3 месяца назад

      how would that work otherwise? There is a pattern there and if you omit "error" and dont subsitute with anything the pattern will just break. Is not what he is criticizing ?

    • @stepans2167
      @stepans2167 3 месяца назад

      @@velifurkanturkoglu1387 you can just put a comma in there without the underscore

    • @tspander
      @tspander 3 месяца назад

      @@velifurkanturkoglu1387you keep the comma. So you write `[, submitAction, isPending]`

  • @earnstein7607
    @earnstein7607 3 месяца назад +1

    We have all these in tanstack, what part of DRY did react developers not get?

  • @igots
    @igots 3 месяца назад

    Imagine debuging why a page has the wrong meta tag when it's some deeply nested component.

  • @claasdev
    @claasdev 3 месяца назад

    Not sure what’s harder to learn, react or rust? (I’m joking) 😄

  • @ramonj360
    @ramonj360 3 месяца назад

    also React Native 0.74 👀

  • @HilaryCheng
    @HilaryCheng 3 месяца назад

    Nth special, I just wants a simplified react management rather adding new hooks for us. Those tons of dependencies with tons of useHooks are nightmare for developers. I just wanna to get a simple state management just like Svelte or Vue. I can't switch to Svelte / Vue due companies policies......

  • @blazi_0
    @blazi_0 3 месяца назад +5

    Instead of adding like 10 new hooks that we dont need, FIX FORMS, PLEASE!

    • @NoProblem76
      @NoProblem76 3 месяца назад

      Save yourself, go htmx

  • @blazi_0
    @blazi_0 3 месяца назад +1

    Who the hell gonna use these hooks 😂

  • @lightblade007
    @lightblade007 3 месяца назад +1

    React has some great concepts wrapped up by bad API 😂

  • @paxdriver
    @paxdriver 3 месяца назад

    36:34 prediction - phantom infinite renders one day. Terrible idea. Explicit is better. I'd much prefer a reliable error than an unreliable rare error after deployment.

  • @e_tas_
    @e_tas_ 3 месяца назад +6

    3:15 don't we have enough concepts referred to as "actions"? server actions, action arguments for reducers...

    • @lukasmolcic5143
      @lukasmolcic5143 3 месяца назад

      if you think of actions as a counter part for pure functions, function which handle side effects, then it makes sense in both cases

    • @e_tas_
      @e_tas_ 3 месяца назад

      @@lukasmolcic5143 Yeah but now you have to do context switching. I think there's just way too many things called the same thing. And for example when I do "server actions" I just think "actions", same with state management I just think "actions" but internally I know what it is... And same with this. I'll be fine but i'm sure it'll be confusing for newer devs. I wonder how many more "actions" there are that I'm not aware of :p

  • @dobryden7196
    @dobryden7196 3 месяца назад

    If you use React long enough you cant just forget the order of elements in the deconstructed hook array. Changing it to object would make it too complicated as all the other hooks would still use arrays and it would be difficult for newcomers to remember which hooks use arrays and which use objects. Also naming is quite easy now as you said.

  • @Fanaro
    @Fanaro 3 месяца назад

    So much of being a web dev is dealing with forms. It's still super disappointing we have to reinvent the wheel every time.

  • @Zeragamba
    @Zeragamba 3 месяца назад

    You doin ok there Theo? You sound really worn out in this video compared to your other stuff.

  • @zcuric
    @zcuric 3 месяца назад

    "React 19 BETA Is FINALLY Here". Dude, c'mon.

  • @kralkatorrik34
    @kralkatorrik34 3 месяца назад

    9:52 You do not need to add underscore. You can just ignore it - `const [,submit, isPending] = useActionState(...)`.

  • @binitrupakheti4246
    @binitrupakheti4246 3 месяца назад

    I hate the naming on the use hook. Should've just named it something else.