Xhr error when loading a partial into modal - lost


i am trying to load a partial (bootstrap modal), but i am getting a xhr 500 error.
basically like this:

but this line throws the error:

$("#modal-window").find(".modal-content").html("<%= j (render ‘new’) %>");

i am on rails 6

any ideas?


What do you see in your console when this 500 error arises? What is the exact error that you see? There’s nothing standing out in the code you’ve posted, but I’m guessing that something is missing when you try to render ‘new’, maybe the path to the partial is not being resolved, maybe the request is coming in via JS and you don’t have a new.js.erb template in the lookup path…?