Simon Kiteley PRO said about 7 years ago on Nested Forms from Scratch :

I'm really torn to whether this approach gives a good user experience. Its so easy to hit back or refresh the browser and loose what you have entered. I tend to use ajax and save as I go along. Wonder what other think?

Is a great tutorial though :)


David Kimura PRO said about 7 years ago on Nested Forms from Scratch :

From a UX perspective, it is consistent with how, by default, other forms work. You're able to refresh the browser or hit the back button to navigate away from normal forms without warning and losing any field changes.

My approach is usually to provide some form validations via javascript. So if the user adds a record or if they modify existing fields on the page, set a variable in JS. If the user navigates away from the page before saving, then show them an alert to prevent leaving the page on accident.


Mike Belyakov said about 7 years ago on Nested Forms from Scratch :

Good video!

The line

$(this).prev('input[type=hidden]').val('1');

will work good only of the form have 1 hidden field. So, better to fetch _delete input with other selector


aramsm said about 7 years ago on Nested Forms from Scratch :

Hello guys,


Im trying to build a dinamyc form for the same ToDo app, with the difference that it has Devise making user auth system. The thing is I cant use coffe.js, cocoon, SimpleForm or any other gem (except for jQuery). So my form is not working and I dont know what is causing it (clicking on add does nothing).


My project is: https://github.com/aramsm/miniapp-autoseg


c.marroquin2106 said about 6 years ago on Nested Forms from Scratch :
Great video. Helped me a lot. Could you please consider to create a video about nested forms but with **Many to Many association**. Same functionality from scratch and also with coccon. Ithink something like that could solve a lot of question in stackoverflow hahaha. For example, you have address and you have your **categories** table and your **products** table. This could be a many to many association and how to add several products when you are creating a category if you have your **category_products** table. Of course you have your scaffolds for categories and products in case you want to create separate. Thanks again.

yewness said about 5 years ago on Nested Forms from Scratch :
Is it possible to have dynamic nested form like this with form object?

sbaron24 said about 3 years ago on Nested Forms from Scratch :
Hello, thanks for the video!  Great step-by-step walkthrough. Everything worked for me except for line 4 in link_to_add_row;  it seems that this does not generate a new id each time I click the add row link in the UI;  it generates the same link each time and thus when I add a bunch of rows and submit the form, the controller receives the data from the last row (not all the rows).  Are you getting the same results?  Am I missing something?  Otherwise, do you have any workarounds if you're having the same issue?   My current workaround is kind of hacky and outside the context of your approach, which is changing the id in the DOM manually (using js or jquery) within the listener on ".fields" every time the link is clicked.

Juanse Caro said about 3 years ago on Nested Forms from Scratch :
I miss the equivalent code in JS for good old useful videos

Login to Comment