Add filtering to main.js and posts_list.js