Make 'filter' param in JS inline with event listener.