added haml
continued refactoring