Routing with subdirectories


My template wont show. I am using angular and express.

With express i have a route in routes.js:

`router.get('/dashboard*', isLoggedIn, function(req, res){

So when i enter localhost/dashboard my dashboard.html is showing.

<script src="libs/angular/angular.min.js"></script>
<script src="libs/angular-route/angular-route.min.js"></script>
<script src="js/app.js"></script>
<script src="js/ngRouter.js"></script>

<base href="/dashboard">

<body ng-app="myApp">

<div id="container">
	<div id="content">
        <div ng-view></div>

"myApp" is is defined in app.js:

angular.module('myApp', []);

and ngRouter.js:

angular.module('myApp').config(function($routeProvider, $locationProvider) {
$routeProvider.when('/home', {
	templateUrl: 'views/dashboard/dashboardHome.html'
	redirectTo: '/home'


The folder hierarchy:

  • app
    • routes.js
  • public
    • js
      • app.js
      • ngRouter.js
    • views
      • dashboard
        • dashboard.html
        • dashboardHome.html

I cant find my problem, ive looked at documentation and searched google


Help me understand something here... Is this a codecademy course or one of your projects? So i can give you the best anwser.


This is one of my own projects


Then This place is not a place to ask those types of questions... Ask Stackoverflow instead...