Octo-Labs / middleman-alias

Easy aliases/redirects for Middleman that are friendly to the Googles.
MIT License
35 stars 14 forks source link

Use JavaScript redirect to keep search and hash #5

Closed wagenet closed 9 years ago

coveralls commented 9 years ago

Coverage Status

Coverage remained the same at 97.22% when pulling 4efc069125f8820f47653569ef341950425a7739 on wagenet:keep-search-and-hash into f114eaf304120bf334b2b3eeed8a23e595349f4c on Octo-Labs:master.

coveralls commented 9 years ago

Coverage Status

Coverage remained the same at 97.22% when pulling 4efc069125f8820f47653569ef341950425a7739 on wagenet:keep-search-and-hash into f114eaf304120bf334b2b3eeed8a23e595349f4c on Octo-Labs:master.

wagenet commented 9 years ago

I chose not to squash since I'm actually using this branch in another project, but I can do that if necessary.

coveralls commented 9 years ago

Coverage Status

Coverage remained the same at 97.22% when pulling cc17b8087cce8c08a3492a2b78a32dcab1c25cac on wagenet:keep-search-and-hash into dfdea89ac5f6ff04b9bb9fee556eec05ab5d9d0a on Octo-Labs:master.

jagthedrummer commented 9 years ago

Any idea how this affects SEO concerns? I know that the meta tag method looks like a 301 redirect to most search engines and preserves the "link juice". Having trouble finding info about what a JS redirect does in that regard.

wagenet commented 9 years ago

@jagthedrummer The meta tag is there the same as always. Crawlers that don't do JS should continue to handle that as before. It's possible (though I don't think likely) that JS enabled browsers would treat the location.replace as special, which would also be fine.

jagthedrummer commented 9 years ago

Sounds good. Sorry for the delay, I just got back from vacation.

jagthedrummer commented 9 years ago

I just pushed middleman-alias-0.0.11.gem, which contains this fix.