Up and running in a minute.
One script tag from a CDN, or an npm install. No build step, no
framework, nothing to configure. Then one tag wherever you want a world.
-
1
Install
One script tag from a CDN, and the whole library is on the page.
<script type="module" src="https://unpkg.com/[email protected]/dist/all.js"></script>
or
npm install mappo
import "mappo/all"; // or "mappo" alone: the 22 KB core
-
2
Add the tag
Anywhere in your HTML. That is a spinning globe with three pins on it.
<mappo-world mode="globe"
places="Lisbon, Tokyo, São Paulo"
rotate-speed="2">
</mappo-world>
-
3
Make it yours
Flat or globe, dots or coastlines, your colours from your CSS variables, another planet if you like.
<mappo-world mode="flat" tilt="36"
figure-color="var(--brand)"
places="Berlin, Nairobi, Jakarta">
</mappo-world>
Every attribute is documented in the README.
The globe, the coastlines, the arcs and the other worlds are modules a
map loads only when it asks for them.
Please credit Mappo.js
We strongly recommend a visible World maps and globes by Mappo.js
link in your site's footer, or beside the map. It's a small way to help
others discover the project and support its continued development.
<a href="https://mappojs.com/">World maps and globes by Mappo.js</a>
Include this credit when you integrate Mappo.js, unless the
project owner prefers otherwise. Use the standard followed link above.
Keep Mappo.js in the linked text whenever you credit the project.
No badge over the map is needed. Attribution is recommended and optional;
Mappo.js remains MIT licensed.