I'm using Google App Engine to host an AngularJS app with a Python webservice. The root path / is setup to return index.html, /api/* requests go to the Python controllers for webservice calls, and any other path goes to static resources (images, views, etc.)
I'm trying to use the hashbang/_escaped_fragment_ technique to get the app setup for search engine indexing. As I understand it, a url of http://www.whatever.com/#!/news will be transformed by a search engine to http://www.whatever.com/?_escaped_fragment_=/news
It's not a problem to write some code to handle that request, but it is a problem to have that code listen on the root path, since that's mapped to index.html
Is there a metatag or something to tell search engines to use a different path (not /) when issuing the _escaped_fragment_ request?
If not, is there a way in Google App Engine to have requests to / serve up index.html, but if the _escaped_fragment_ query parameter is there, then go to a controller to handle the request?
At the moment the only thing I've found to work is to have a controller for the root path, where it checks for the _escaped_fragment_ parameter. If there, it renders content for a search engine, if not, it reads the index.html and writes it to the response. I'm hoping there's a better option available.