Have been using cocoon gem
for nested forms in rails 4 & rails 5 apps. Currently, I was updating one of the rails 5.2 app (which is using cocoon gem) to rails 6.
As rails 6 is using webpacker, so I tired to require cocoon javascript in application.js
file as we used to do in previous versions of rails.
app/javascript/application.js
//= require cocoon
But unfortunately, things do not seem to work. Have also tried to import but of course, it's also not working as the cocoon is not available as a javascript package.
Any solution or alternate for this?