Previously I was using Angular 2 alpha 48. I've recently upgraded to beta 1.

Formerly, my site had this URL scheme for different pages:
http://localhost:51179/index.html#report
http://localhost:51179/index.html#preview

Now, I find that using router to go to the 'report' page brings up this:
http://localhost:51179/report

Initially this works.... in Chrome. But upon hitting the Refresh button in 
the browser, I then get 404 Not Found.

And when using a somewhat older WebKit framework from C++ to load teh page, 
it doesn't work at all.

Did something change with router that I must update to get it to work the 
old way, using #report, or is /report the 'new' way, and I need to do 
something else to get it to work when refreshed?

-Vern

Relevant code from app.ts below, for those curious...

import { ROUTER_PROVIDERS, ROUTER_DIRECTIVES, ROUTER_PRIMARY_COMPONENT, 
APP_BASE_HREF, RouteConfig, RouterLink, RouterOutlet,
  Router, Route, Location, LocationStrategy, HashLocationStrategy, 
PathLocationStrategy
} from 'angular2/router';


@RouteConfig([
    new Route({path: '/', component: Report, name : 'Report'}),
new Route({path: '/report', component: Report, name : 'Report'}),
new Route({path: '/preview', component: Preview, name : 'Preview'})
])

// inside my App class...
ngOnInit()
{
this.router.navigate(['/Preview']);
}


-- 
You received this message because you are subscribed to the Google Groups 
"AngularJS" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.

Reply via email to