Few months ago Google changed their policies on how to let users use their maps. It caused many problems for users who were using google maps. Even though they still have free service defined by their limits having to give credit card information ahead of time to use maps seems to be too much. So in this post I am going to write about an open source library which can do thing for us.
To use the map we just need to put these two tags in our head section
Then we can write following code to put the map in our code
Here first parameter of setView is array of latitude and longitude and second parameter is zoom level.
After initializing the map, we can simply add marker to map and if we want we can also put link of google maps. This will create the following output.
Which is what we want. We can also place multiple markers and make this map a lot better. I recommend you to visit leaflet website for more documentation.