iron-meteor / iron-router

A client and server side router designed specifically for Meteor.
MIT License
1.98k stars 414 forks source link

Not Found Template Not Working with Angular-Meteor #1526

Open danielflippance opened 8 years ago

danielflippance commented 8 years ago

I'm using angular-blaze-template to allow me to override the IronRouter notFoundTemplate, but it's not working. I'm using iron:router@1.0.12 for server side routes only and angular-meteor for client side routes, but I found that IronRouter inserted it's notFoundTemplate error into every page. I tried to get rid of the message by adding my own notFoundTemplate but without success. I've added this template into my angular /client/index.html:

<head>
    <base href="/"> 
</head>

<template name="ironrouternotfound">
    IR Not Found
</template>

<body>
    <div ng-app="myapp" ng-strict-di="">     
        <div ui-view autoscroll="true"></div>
    </div>  
    <blaze-template name="ironrouternotfound"></blaze-template>
</body>

Configured IronRouter to use it - /client/router.js

Router.configure({
    notFoundTemplate: "ironrouternotfound"
});

However I see the message:

"Couldn't find a template named "ironrouternotfound" or "ironrouternotfound". Are you sure you defined it?"

I've also tried using angular-with-blaze but that also doesn't remove the iron router message. Full description of that here: http://stackoverflow.com/questions/34519752/prevent-iron-router-not-found-template-showing-when-using-angular-meteor

albertonaperijr commented 8 years ago

+1 Not working for me neither.

FlawaCLV commented 8 years ago

+1

Not working for me neither.