Google's crawler won't understand own maps. How to workaround?

前端 未结 6 1887
我寻月下人不归
我寻月下人不归 2021-02-13 23:18

I found strange words, (have, here, imagery, sorry) that were supposed not to be on my site, being taken as keywords by the crawler from Google

6条回答
  •  闹比i
    闹比i (楼主)
    2021-02-13 23:25

    "Solution" applied:

    I had one different map per each page in my site, I ended up converting all maps to images and only keep one interactive map where I really needed user interaction with coordinates and mapping stuff. The solution I used led me to create and opensource [osm-static-maps][3]. Hope it helps somebody!

    The site got several improvements:

    • Got rid of this awkward words in google webmasters.
    • More relevant SEO using static images with "alt" html img attribute instead of "unindexable" js map.
    • Faster page loading (got rid of all mapping libraries and tile loading).
    • Faster js performance (less js to process by client)
    • Improved user experience: scrolling page caused map zooming instead of actually scrolling (you can think that this could be solved by disabling map scroll to zoom, but it lead to a user expecting to zoom the map on scroll, both ways were [ok and wrong at the same time][4]).

    On the downside, I found:

    • Less user interactivity (boring page).
    • Less context on the map (less informative map).

    This two things could be "fixed" loading the map when the user clicks the map img. The bad side is that if the user clicks the map img unintentionally, the map load can be seen as unexpected behaviour by the user.

    Edit2

    I made an opensource project out of this. Check out! https://github.com/jperelli/osm-static-maps

提交回复
热议问题