title: Durandal / Require.JS - signalr/hubs reference not found
body: <p>I'm using the "HotTowel" Single Page App Template, but I'm not being able to get SignalR working. I'm getting the following error:</p>
  
  <pre><code>Failed to load resource: the server responded with a status of 404 (Not Found)
  http://localhost:8184/signalr/hubs
  </code></pre>
  
  <p>I had a kind of boilerplate using the standard MVC 4 Single Page App, with a very simple hub in place (users online counter). Everything was working fine.</p>
  
  <p>After I switched to "HotTowel" it stopped working. I checked with John Papa and he gave me a suggestion to check in the Durandal side, as he mentioned he knew some fix was about to be done on some issues interfering with some routing.</p>
  
  <p><strong>main.js:</strong></p>
  
  <pre class="lang-js prettyprint-override"><code>require.config({
    paths: {
      "text": "durandal/amd/text",
      "signr": "../scripts/jquery.signalR-1.0.1.min"
    }
  });
  define(['durandal/app', 'durandal/viewLocator', 'durandal/system', 'durandal/plugins/router', 'services/logger', "signr"],
    function (app, viewLocator, system, router, logger, sigr) {
  
    // Enable debug message to show in the console
    system.debug(true);
  
    app.start().then(function () {
      toastr.options.positionClass = 'toast-bottom-right';
      toastr.options.backgroundpositionClass = 'toast-bottom-right';
  
      router.handleInvalidRoute = function (route, params) {
        logger.logError('No Route Found', route, 'main', true);
      };
  
      // When finding a viewmodel module, replace the viewmodel string 
      // with view to find it partner view.
      router.useConvention();
      viewLocator.useConvention();
  
      // Adapt to touch devices
      app.adaptToDevice();
      //Show the app by setting the root view model for our application.
      app.setRoot('viewmodels/shell', 'entrance');
    });
  });
  </code></pre>
  
  <p><strong>Global.asax.cs:</strong></p>
  
  <pre class="lang-cs prettyprint-override"><code>protected void Application_Start()
  {
      FilterConfig.RegisterGlobalFilters(GlobalFilters.Filters);
      // Register the default hubs route: ~/signalr/hubs
      RouteTable.Routes.MapHubs();
      RouteConfig.RegisterRoutes(RouteTable.Routes);
      BundleConfig.RegisterBundles(BundleTable.Bundles);
  }
  </code></pre>
  
  <p><strong>HotTowel\index.cshtml:</strong></p>
  
  <pre class="lang-html prettyprint-override"><code>&lt;body&gt;
    &lt;div id="applicationHost"&gt;
      @Html.Partial("_splash")
    &lt;/div&gt;
  
    @Scripts.Render("~/scripts/vendor")
      @if(HttpContext.Current.IsDebuggingEnabled) {
        &lt;script type="text/javascript" src="~/App/durandal/amd/require.js" data-main="@Url.Content("~/App/main")"&gt;&lt;/script&gt;
      } else {
        &lt;!-- Remember to run the Durandal optimizer.exe to create the main-built.js  --&gt;
        &lt;script type="text/javascript" src="~/App/main-built.js"&gt;&lt;/script&gt;
      }    
    &lt;script type="text/javascript" src="~/signalr/hubs"&gt;&lt;/script&gt;    
    @*&lt;script src="~/App/services/hubs.js"&gt;&lt;/script&gt;*@
  &lt;/body&gt;
  </code></pre>
  
  <p>(I know this probably isn't the place to put it, but I couldn't make it appear on my sources, until I've put it here) - by the way, if you can show me the correct way to do it, I'll appreciate</p>
  
  <p>What else can I tell you to help me troubleshoot this? I have all references to SignalR, etc... I have a working example using another project template...</p>
  
  <p>Can someone guide me ?    </p>
  
  <p>It should be easy enough to replicate:</p>
  
  <ol>
  <li>Just use the "HotTowel" template  </li>
  <li>Add all SignalR references  </li>
  <li>Test with my code  </li>
  </ol>
  
  <p>I'm thinking either Durandal or Require.Js are getting in the way with this. Can someone save the day? :)</p>