refactoring of view rendering #coderwall #pimf