title: routing doesn't work in angularJS and throws exception of [$injector:modulerr]
body: <p><div class="snippet" data-lang="js" data-hide="false" data-console="true" data-babel="false">
  <div class="snippet-code">
  <pre class="snippet-code-html lang-html prettyprint-override"><code>&lt;!DOCTYPE html&gt;
  &lt;html&gt;
  &lt;script src="http://ajax.googleapis.com/ajax/libs/angularjs/1.4.8/angular.min.js"&gt;&lt;/script&gt;
  &lt;script src="//ajax.googleapis.com/ajax/libs/angularjs/1.4.8/angular-route.js"&gt;&lt;/script&gt;
  
  &lt;body ng-app="myApp"&gt;
  
  &lt;p&gt;&lt;a href="#/"&gt;Main&lt;/a&gt;&lt;/p&gt;
  
  &lt;a href="#banana"&gt;Banana&lt;/a&gt;
  &lt;a href="#tomato"&gt;Tomato&lt;/a&gt;
  
  &lt;p&gt;Click on the links to change the content.&lt;/p&gt;
  
  &lt;p&gt;The HTML shown in the ng-view directive are written in the template property of the $routeProvider.when method.&lt;/p&gt;
  
  &lt;div ng-view&gt;&lt;/div&gt;
  
  &lt;script&gt;
  var app = angular.module("myApp", ["ngRoute"]);
  app.config(function($routeProvider) {
      $routeProvider
      .when("/", {
          template : "&lt;h1&gt;Main&lt;/h1&gt;&lt;p&gt;Click on the links to change this content&lt;/p&gt;"
      })
      .when("/banana", {
          template : "&lt;h1&gt;Banana&lt;/h1&gt;&lt;p&gt;Bananas contain around 75% water.&lt;/p&gt;"
      })
      .when("/tomato", {
          template : "&lt;h1&gt;Tomato&lt;/h1&gt;&lt;p&gt;Tomatoes contain around 95% water.&lt;/p&gt;"
      });
  });
  &lt;/script&gt;
  
  &lt;/body&gt;
  &lt;/html&gt;</code></pre>
  </div>
  </div>
  </p>
  
  <p>I have a following code which is implementing a very simple routing example. But unfortunately It doesnot work and there is an error of [$injector:modulerr] in angular.min.js (38,282).</p>