You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
minor #14340 [Collection forms] Make javascript generic (tcheymol)
This PR was submitted for the master branch but it was merged into the 4.4 branch instead.
Discussion
----------
[Collection forms] Make javascript generic
This pull request aims at making javascript code on the "embeded collection form" section reusable in any form collection
* The aim is that we only need to add a `<ul>` tag, and add one init line in javascript if we embed another form collection
* Also, I think that the `$addLinkLi` can perfectly be added in Twig instead of javascript, it reduces the size of the js function and improoves reusability
What I did is
* Remove the `$addLinkLi` from javacripts
* Add a data attribute to it so it can reference the list container class : `data-collection-holder-class`
I created a sample project implementing my working solution [here](https://github.com/tcheymol/embeed_form_collection_test)
Commits
-------
3abeceb [Collection forms] Make javascript generic
0 commit comments