Convert index to haml