Ruby on Rails #59 Hotwire Turbo Streams CRUD

Поделиться
HTML-код
  • Опубликовано: 24 ноя 2024

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

  • @mr.movies7910
    @mr.movies7910 6 месяцев назад +1

    I have parctice all in 5 hours learn a lot from you man.

  • @tomdringer985
    @tomdringer985 Год назад +4

    Easily the best Turbo Streams example i've seen. Very easy to understand. Thank you!

    • @SupeRails
      @SupeRails  Год назад

      You're very welcome! ☺️

  • @nathangillespie5421
    @nathangillespie5421 2 года назад +4

    You made this a lot more understandable than other tutorials because you shown the responses in dev tools. Other videos have you create an id for the elements without explaining that's how it is targeted by turbo. Thanks!

  • @mikopiko
    @mikopiko 2 года назад +4

    Such a beautiful introduction to Hotwire and Turbo specifically! Thank you.

  • @Ilmattosulcolle
    @Ilmattosulcolle 2 года назад +2

    This is THE guide I was looking for. Your explanations are SUPERB

  • @edyta9877
    @edyta9877 Год назад

    Amazing content! Best explanation about turbo available. Thanks for your work.

  • @haroldpepete
    @haroldpepete 2 года назад +1

    you do a great job, turbostream sometimes look like magic that even you are surprised, i don't miss any video of your channel

  • @BenjaminMahmood
    @BenjaminMahmood 5 месяцев назад

    Finally I am starting to understand it! Great video!

  • @pging8328
    @pging8328 11 месяцев назад

    hey thanks for the video
    btw: git commit -m -----> the -m flag denotes msg, not "main" as referred to in the video.

  • @rahulk6130
    @rahulk6130 Год назад

    Wonderful tutorial. Well explained, and the pace was good. Wondering how I can make the buttons in one line rather than stacked.

  • @muniruddin8295
    @muniruddin8295 2 года назад +1

    Superb !! Very clear explanation. Thanks for making this.

  • @erdemtopal4107
    @erdemtopal4107 2 года назад +2

    İt was really benaficial. Thanks a lot. Turbo is going to be new react. React is too complicated when i compare with stream.

  • @christianconcepcion4914
    @christianconcepcion4914 2 года назад +1

    This tutorial what I'm looking for! Thank you so much sir!

  • @marknelson8114
    @marknelson8114 2 года назад +2

    Very clear explanation, thank you.

  • @GajendraSingh-nl6rb
    @GajendraSingh-nl6rb 3 года назад +3

    You video are very helpful for me for my production project

    • @SupeRails
      @SupeRails  2 года назад

      Glad to hear that! What are you building?

  • @edmundo5450
    @edmundo5450 2 года назад +4

    Big thanks for the tutorial. I follow the coding and its a joy to see it works. For my practice, i tried to do it for a simple two column table (i.e. Name and age). However, i cant make to work with Edit and Destroy. Is there any suggestions for "turboing" a table. Would be nice, if a tutorial can be planned for these. I'm sure it will be a big hit for newcomers like me. Thanks again.

    • @SupeRails
      @SupeRails  2 года назад +1

      Hello Edmundo!
      There seems to be no good-enough way to use hotwire within the HTML tag. You can see the discussion here: github.com/hotwired/turbo/issues/48
      I would recommend sticking to non-table columns with Hotwire stuff, at least for now ;)

    • @edmundo5450
      @edmundo5450 2 года назад

      I saw this article already, so instead of using HTML tag, i used divs to create the table as suggested by the readers on that article. Create is working properly. Destroy, i need two clicks to the button to delete the row and Edit can display the form after click button.

  • @tariqhussain5396
    @tariqhussain5396 11 месяцев назад

    Great work!!! Very well explained, Thanks

  • @MohsinTariq-c5t
    @MohsinTariq-c5t Год назад

    Learned a lot from you, You are doing great Job brother.

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

    Very helpful, thank you!

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

    please tell me/us, let us know, how different is it , or what is the difference when, the flow, the code, when one creates files like , templates like, `views/messages/create.turbo_stream.erb` and so on. why didn't you use those types of templates. thanks in advance. and, once again (something that is evident, unhideable); your channel rocks ruby all over the place! ha

    • @SupeRails
      @SupeRails  Год назад

      very good question!
      for stuff that can be done inline, it’s enough to do it from controller directly.
      but I believe that having turbo_stream.erb templates is ultimately A BETTER approach

  • @aeroplane769
    @aeroplane769 3 года назад +3

    Wonderful tutorial!!

    • @SupeRails
      @SupeRails  2 года назад

      Hello Vishal! Thanks for the feedback. I'm really enjoing Turbo and all it's possibilities a lot lately

  • @kiruieli254
    @kiruieli254 2 года назад +2

    Awesome tutorial 🙌

  • @ruby-on-rails
    @ruby-on-rails 2 года назад

    Amazing tutorial! I created an inline SPA form just by watching your tutorial and it's working!
    There's one issue though when the flash message displays we need a way to make it go away after a few seconds. I am wondering if that's possible with turbo. I fit isn't how would you implement it in Javascript?
    BIG THANKS!!🙏

    • @SupeRails
      @SupeRails  2 года назад

      Hello Juzer! I've got a video about flash messages that answers your question here: ruclips.net/video/mAANmoNgOKA/видео.html

    • @ruby-on-rails
      @ruby-on-rails 2 года назад +2

      @@SupeRails Yes! I am just watching that! 🙂 Your a Rails hero! 😀👌

  • @terng_gio
    @terng_gio 2 года назад +2

    I have a user and a message model, im trying to put a delete link if the message is belongs to current user, but that doesn't seem to work, I have to refresh the page in order to see the delete link. Any opinion?

    • @SupeRails
      @SupeRails  2 года назад +1

      See the console logs. Do you get "Request forgery protection requires a working session store but your application has sessions disabled."?
      Here's how you can fix that:
      blog.corsego.com/turbo-stream-button-to-update-value-and-refresh-frame

  • @leandrocl5724
    @leandrocl5724 2 года назад

    gracias papi que chevere tu contenido, saludos desde peru :D

  • @RomanA-p6h
    @RomanA-p6h 2 года назад

    После просмотра этого ролика - мне захотелось перейти с Symfony на RoR =)

  • @agustinpalmam2923
    @agustinpalmam2923 2 года назад

    Great video man, thanks

  • @faraznaeem
    @faraznaeem 3 года назад +3

    Great tutorial!

    • @faraznaeem
      @faraznaeem 3 года назад +2

      Is there a way to make the notice disappear after a few seconds using only turbo?

    • @SupeRails
      @SupeRails  2 года назад +1

      You would want to use a stimulus controller for that. See section #5 of this blogpost: blog.corsego.com/turbo-hotwire-flash-messages

  • @jeremybrews2521
    @jeremybrews2521 2 года назад

    this was really cool ty

  • @sufyaniqbal3636
    @sufyaniqbal3636 2 года назад +1

    It's great. I will waite for stimulus and trada too. And how we can handle streem at model level

    • @SupeRails
      @SupeRails  2 года назад

      Hello Sufyan. From a model level you would be doing "broadcasts". Here are my notes on that: blog.corsego.com/turbo-hotwire-broadcasts

    • @mikopiko
      @mikopiko 2 года назад

      Looking forward to see Strada get released!

  • @felipehansen4932
    @felipehansen4932 2 года назад

    What a good content, thanks

  • @salomaonovacena6198
    @salomaonovacena6198 2 года назад

    Hey SuperRails, nice nice. Rails 7 API course?

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

    hey man love you.

  • @GajendraSingh-nl6rb
    @GajendraSingh-nl6rb 3 года назад +2

    Hello , I am new in rails , can you guide me how to archive in mastery in rails

    • @SupeRails
      @SupeRails  2 года назад +1

      Read a lot of blogs, experiment a lot on your own pet-projects. Try building something big and experimental on your own :)

  • @TruongNguyen-jy6nt
    @TruongNguyen-jy6nt 2 года назад

    I follow the code and it's not working for me. I see the Network and it appears requests with status 200 but nothing change until i refresh the page. What can i do to fix this issue?

    • @SupeRails
      @SupeRails  2 года назад +1

      what exactly is not working? timecode?

    • @TruongNguyen-qw1sp
      @TruongNguyen-qw1sp 2 года назад

      @@SupeRails my html is not changing. Seems like turbo don't modify my page. I don't know why

  • @omhr9554
    @omhr9554 2 года назад +1

    ubuntu + ruby on rails + postgresql NEVER worked easily, at least never as easy did for you I had to create database with pgAdmin RoR never created it for me

    • @SupeRails
      @SupeRails  2 года назад +1

      In my experience, I set up rails+postgres+ubuntu on AWS Cloud9 IDE and it works pretty well for me.
      Here's my script for installing Rails 7, postgres: blog.corsego.com/install-ruby-on-rails-7-on-ubuntu
      Here - for setting up the basics of postgres: blog.corsego.com/ruby-on-rails-install-postgresql
      Hope my experience helps you at least a bit :)