added router to main.js and moved views to route.js