it means, all the routes that you have set up in your SPA, should have corresponding Rails routes. So when you are hitting that route directly in browser, your rails app can serve html that has references to your angular app javascript and styles.
In case of hash bang and ie9 it depends how far you want to go, your root route, should serve mark up that has references to javascript and styles, so once app loads it can react to /#!/v2/challenges/new. There are other things you can do, for example if some one comes from normal url from search, but user agent is ie9, you could redirect to root with hash bang equivalent of that route. On Wednesday, April 23, 2014 3:54:44 PM UTC-5, Yale Kaul wrote: > > I've been working on an AngularJS/Rails app that must support IE9. From > what I've read, I should set html5Mode to true in my AngularJS config, > which will use the HTML5 History API for browsers that support it, and fall > back to hashbang URLs for older browsers. All of the Angular stuff in my > app is rooted at */v2/challenges/.* > > In the fantastic ng-book <https://www.ng-book.com/>, it says: > > "The back-end server will have to support URL rewriting on the server > side. To support HTML5 mode, the server will have to make sure to deliver > the index.html page for all apps. That ensures that our Angular app will > handle the route." > > What does that mean specifically? > > If my AngularJS content is at /v2/challenges/new (which appears as > /#!/v2/challenges/new in IE9), > > ...what does that mean for me in terms of the URL rewriting I need to do > on the server side? > > > Thanks! > -- 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 http://groups.google.com/group/angular. For more options, visit https://groups.google.com/d/optout.
