I want to pass my local variable to escape_javascript like this:
function renderPartial(partial) {
$('body').append('<%=escape_javascript render(:partial => partial) %>');
}
But I got an error: undefined local variable or method `partial' for #<#:0x00007f9be09a36b0>
So my question is how I can pass my local variable in the case.