3 ms·
http://stackoverflow.com/questions/6193858/pushstate-and-seo http://stackoverflow.com/questions/6193858/pushstate-and-seo pushState's SEO issues.
by Hipchan 15y ago
http://stackoverflow.com/questions/6193858/pushstate-and-seo http://stackoverflow.com/questions/6193858/pushstate-and-seo
pushState's SEO issues.
- zmanji 15y agoHow can there be SEO issues? I thought the whole point of pushState was to allow AJAX loading of content (without refresh) but not break URLS with #!.
- alecperkins 15y agoThere aren't if used correctly. The SO questioner has a misunderstanding of how the history API and the hashbang scheme are supposed to work.
- odiroot 15y agoOr you could use progressive JavaScript, AFAIK. Make your every link a first class citizen (with it's own view) and for supported browsers replace links' default action with content switching (without reloading) using JS requests. Of course that's a bit harder since your views need to respond in a different manner to casual GETs and AJAX requests.
- encoderer 15y agoWhich really should be trivial using most modern 3-Tier frameworks. They universally have a concept of "layout" vs "template" so in a pseudocode logic, all you need to do is tap into the render method and swap out an empty layout when responding to an XHR request.
- odiroot 15y agoExactly, however one can argue the number of your test cases (and cache entries) doubles. Still I think it's an elegant solution.