A simple demo with get lat+lon functionality shows off Squares’s core features:
- Seam-free panning and zooming of tiled maps/images
- Use of CSS transforms where available
- Smooth mouse-wheeling with D3's normalized mouse-wheel delta
- Mercator projection support, basic understanding of geography
- Built-in URL hash for linking
Although D3 includes a plug-in tile implementation,
I believe that a complete library should include a first class tile layer
and coordinate data model. I’m also interested in how the tile layer abstraction
can be adapted to non-image tiles, especially with new browser technologies
like WebGL. At Stamen, we experimented with an earlier version of this library
and interactions with WebGL in the Burning Map project.
Squares is a more formal library built on this idea, and includes a traditional
image-based map as well as a
DIV-only map demonstrating non-image uses.
If you’re interested in traditional image-tiled maps, an extensive plug-in ecosystem and user community, complete documentation and a stable API, then Squares is probably not for you. Consider Modest Maps or Leaflet for your lightweight mapping needs.
About D3 and Typescript
Learn more at d3js.org.
Learn more at typescriptlang.org.