Дуже цікаво. Деякі речі, наприклад вбудований турбо стрим, це взагалі щось нове! Дуже за це дякую) Разом з тим, якщо вже використовуємо стімулус, то додаткова кнопка форми зайва. Додати ще одно value і сформувати запит безпосередньо у стімулус контролері, у заголовок додати очікувану відповідь у турбо стрим форматі. Одночасно цим же контролером можно контролювати зміст парамс, щоб не виводити зайвого у строчці браузера. Ярослав, ще раз дякую! Подивився як чашку гарної кави випив) Слава Україні!
Great tutorial, but I hit 2 issues: 1. simple_form does not let me create a button with get action on form (might have to bypass simple_form) 2. i got around the first problem by creating a submit button with a different commit parameter, and catch the submission in the create controller method: " if params[:commit].eql? 'validate' return render :new end" however the submit will not be invoked if html 5 is validating required fields Any ideas?
@@SupeRails I saw it in book "modern frontend for ruby on rails" but your english more undestanable for me )))). In this book author show some intresting thing as "stimulate". I think you can explain better )))
@@ddd2283 oh, got it! I'm aware of stimulus reflex, and I know that it can do similar things as hotwire/turbo. However I don't have enough practical experience with it to be able to cover it in a good video at the moment. SR sure is on my TODO list for when I know it well enough :)
interesting question. in this scenario where “new” and “edit” share the same form, I suppose it’s still ok to submit the “form.button” to “new_post_path”. If I create a record and open the edit form, everything seems to be working ok
Ok now I really understand where you were going. assign_attirbutes seems to be a good solution. I've used it today for a PR at work where I had to partially update an "Edit" form and worked very well
bro, i think you're a modern version from ryan bates or even better.. love your tutorial, i learned much from here..
Hello Andre! Thanks a lot! I’m trying my best 🤠
Thanks for the guide! Good job.
Дуже цікаво. Деякі речі, наприклад вбудований турбо стрим, це взагалі щось нове! Дуже за це дякую)
Разом з тим, якщо вже використовуємо стімулус, то додаткова кнопка форми зайва. Додати ще одно value і сформувати запит безпосередньо у стімулус контролері, у заголовок додати очікувану відповідь у турбо стрим форматі. Одночасно цим же контролером можно контролювати зміст парамс, щоб не виводити зайвого у строчці браузера.
Ярослав, ще раз дякую! Подивився як чашку гарної кави випив)
Слава Україні!
Вітаю! Чи міг би ти показати що ти маєш на увазі у форматі gist? :)
@@SupeRails Звісно.
Thank you,very clearly explained
very clear, strong base, loved
I love you! thanks
Great tutorial, but I hit 2 issues:
1. simple_form does not let me create a button with get action on form (might have to bypass simple_form)
2. i got around the first problem by creating a submit button with a different commit parameter, and catch the submission in the create controller method: " if params[:commit].eql? 'validate'
return render :new
end"
however the submit will not be invoked if html 5 is validating required fields
Any ideas?
I enjoy your content! Thanks so much!
How do you show validation errors using turbo?
How can this be used with nested form fields (accepts_nested_attributes_for)?
if you want to "add/remove" nested fields, you would need something else. like gem vanilla_nested, or some other solution
Dont forget to enter this command after creating a stimulus controller :
./bin/rails stimulus:manifest:update
Hi Yaroslav! Can you explain turbo + action_cabe integration in some video. Thanks!
I wish I could 😂
I'll put it on the backlog +
@@SupeRails I saw it in book "modern frontend for ruby on rails" but your english more undestanable for me )))). In this book author show some intresting thing as "stimulate". I think you can explain better )))
I was wrong about naming this technology , I mean StimulusReflex , this example official ruclips.net/video/dPzv2qsj5L8/видео.html
Anyway , still waiting your awesome explanation😀
@@ddd2283 oh, got it! I'm aware of stimulus reflex, and I know that it can do similar things as hotwire/turbo. However I don't have enough practical experience with it to be able to cover it in a good video at the moment. SR sure is on my TODO list for when I know it well enough :)
what's the shortcut to back to the terminal
alt+tab? did I understand your question correctly? 😄
Can u make a video about active storage and presigned url s3 upload?
It's more like an hack! You can avoid hidden button click at all.
Hey Paul! I wouldn't call it a hack. It's quite a reliable approach, leveraging only normal http requests and Hotwire
How do you deal with the edit side and persisting the params? Maybe use @post.assign_attributes(post_params)
interesting question. in this scenario where “new” and “edit” share the same form, I suppose it’s still ok to submit the “form.button” to “new_post_path”. If I create a record and open the edit form, everything seems to be working ok
Ok, I see an issue: when you go to "edit" and refresh the page, the selection can look "broken". I will show my solution in episode #82
Ok now I really understand where you were going. assign_attirbutes seems to be a good solution. I've used it today for a PR at work where I had to partially update an "Edit" form and worked very well