Wip #218 and #220. Finally fixed the re-rendering of filter.js with help from @cristiandouce