Refactor homes index page