refactoring views with proper indentation