Refactor the jade files