Adding configuration view and refactoring the router