# MapCairn documentation > Documentation for the MapCairn SDK Every page is also a plain Markdown file, linked below with its size. The full text is split by area into the files listed first, none larger than 150000 bytes unless it is a single page: read this index, then fetch only the file or page you need. The API reference has a page for every export, so only its front page and each package's page are listed here; a package's page links its members, and their text is in that package's files. The pages and the API reference are also data, in https://docs.mapcairn.com/pages.json and https://docs.mapcairn.com/api.json; the Machine-readable data page describes them. ## Full text by area - [llms-full-guides-1.txt](https://docs.mapcairn.com/llms-full-guides-1.txt): guides, part 1 of 3 (Get started with the MapCairn SDK to Layer definitions), 11 pages, 131416 bytes - [llms-full-guides-2.txt](https://docs.mapcairn.com/llms-full-guides-2.txt): guides, part 2 of 3 (Translate the SDK to The public API), 5 pages, 120634 bytes - [llms-full-guides-3.txt](https://docs.mapcairn.com/llms-full-guides-3.txt): guides, part 3 of 3 (Capability matrix to Roadmap), 10 pages, 141131 bytes - [llms-full-core-1.txt](https://docs.mapcairn.com/llms-full-core-1.txt): core, part 1 of 7 (@mapcairn/core to MessageCatalogue), 13 pages, 149980 bytes - [llms-full-core-2.txt](https://docs.mapcairn.com/llms-full-core-2.txt): core, part 2 of 7 (RoutingProvider to computeDetentHeights), 120 pages, 149420 bytes - [llms-full-core-3.txt](https://docs.mapcairn.com/llms-full-core-3.txt): core, part 3 of 7 (computeEndStackMaxHeight to planRequestedImage), 161 pages, 149518 bytes - [llms-full-core-4.txt](https://docs.mapcairn.com/llms-full-core-4.txt): core, part 4 of 7 (pngHeader to BoundingBox), 199 pages, 149360 bytes - [llms-full-core-5.txt](https://docs.mapcairn.com/llms-full-core-5.txt): core, part 5 of 7 (Bounds to MapVectorTiles), 160 pages, 149753 bytes - [llms-full-core-6.txt](https://docs.mapcairn.com/llms-full-core-6.txt): core, part 6 of 7 (MarkerShape to runLayerSourceContract), 132 pages, 149161 bytes - [llms-full-core-7.txt](https://docs.mapcairn.com/llms-full-core-7.txt): core, part 7 of 7 (runLocationProviderContract to UrlStateSubject), 62 pages, 65716 bytes - [llms-full-react.txt](https://docs.mapcairn.com/llms-full-react.txt): react (@mapcairn/react to ReadingDirection), 10 pages, 12057 bytes - [llms-full-theme.txt](https://docs.mapcairn.com/llms-full-theme.txt): theme (@mapcairn/theme to ZLayerName), 33 pages, 38976 bytes - [llms-full-map-1.txt](https://docs.mapcairn.com/llms-full-map-1.txt): map, part 1 of 3 (@mapcairn/map to usePreferences), 103 pages, 149668 bytes - [llms-full-map-2.txt](https://docs.mapcairn.com/llms-full-map-2.txt): map, part 2 of 3 (useResolveText to ShapesSectionProps), 133 pages, 146737 bytes - [llms-full-map-3.txt](https://docs.mapcairn.com/llms-full-map-3.txt): map, part 3 of 3 (SheetContentProps to VisuallyHiddenProps), 35 pages, 50065 bytes - [llms-full-adapter-maplibre.txt](https://docs.mapcairn.com/llms-full-adapter-maplibre.txt): adapter-maplibre (@mapcairn/adapter-maplibre to MapLibreMapAdapterOptions), 4 pages, 4052 bytes - [llms-full-sdk.txt](https://docs.mapcairn.com/llms-full-sdk.txt): sdk (@mapcairn/sdk), 1 page, 1333 bytes - [llms-full-architecture-1.txt](https://docs.mapcairn.com/llms-full-architecture-1.txt): architecture, part 1 of 2 (Architecture to Data layers), 7 pages, 138193 bytes - [llms-full-architecture-2.txt](https://docs.mapcairn.com/llms-full-architecture-2.txt): architecture, part 2 of 2 (Drawing to The reference host's pages), 4 pages, 20515 bytes - [llms-full-design-1.txt](https://docs.mapcairn.com/llms-full-design-1.txt): design, part 1 of 3 (Design system to Components and accessibility contracts (part 2 of 6)), 8 pages, 135016 bytes - [llms-full-design-2.txt](https://docs.mapcairn.com/llms-full-design-2.txt): design, part 2 of 3 (Components and accessibility contracts (part 3 of 6) to Components and accessibility contracts (part 5 of 6)), 3 pages, 114957 bytes - [llms-full-design-3.txt](https://docs.mapcairn.com/llms-full-design-3.txt): design, part 3 of 3 (Components and accessibility contracts (part 6 of 6) to What the lint checks, and where), 4 pages, 72558 bytes - [llms-full-changelog.txt](https://docs.mapcairn.com/llms-full-changelog.txt): changelog (Changelog to Release 0.1.0-rc.1), 6 pages, 32144 bytes ## Pages - [Get started with the MapCairn SDK](https://docs.mapcairn.com/index.md): Install the MapCairn SDK and draw a working map in a Vite and React app, with every file on this page. (9393 bytes) - [Choose a basemap](https://docs.mapcairn.com/tasks/choose-a-basemap.md): Let people pick a basemap, show its credits, and offer only the basemaps you want. (7867 bytes) - [Add a data layer](https://docs.mapcairn.com/tasks/add-a-layer.md): Describe a raster tile layer as data, give it to the services and turn it on over the map. (8313 bytes) - [Draw and edit shapes](https://docs.mapcairn.com/tasks/draw-shapes.md): Add the draw tool to a map so people can place points, lines, areas and circles, edit them, and export them. (8709 bytes) - [Theme the interface](https://docs.mapcairn.com/tasks/theme-the-interface.md): Give the interface your own colours, font and corners with a stylesheet that refuses colours too faint to read. (6336 bytes) - [Switch between light and dark](https://docs.mapcairn.com/tasks/follow-the-system-theme.md): Follow the system's light or dark setting and let people choose between light, dark and system, with the basemap changing alongside. (4886 bytes) - [Translate the interface](https://docs.mapcairn.com/tasks/translate-the-interface.md): Change the words the interface shows, or offer a choice of languages, without forking a component. (9504 bytes) - [Host the map on a server-rendered page](https://docs.mapcairn.com/tasks/host-on-a-server-rendered-page.md): Render the page on the server with a placeholder where the map goes, then draw the map in the browser after hydration. (8761 bytes) - [Embed a map](https://docs.mapcairn.com/guides/embed-a-map.md): What each part of the Get started app does, what a strict Content Security Policy needs, and how another bundler serves the worker file. (3360 bytes) - [Extending MapCairn](https://docs.mapcairn.com/guides/extending.md): What an app around the SDK provides, and how to add a basemap, a data layer, a search provider, a routing provider or an adapter of your own. (37589 bytes) - [Layer definitions](https://docs.mapcairn.com/guides/layer-definitions.md): What a data layer definition holds, a minimal working example, and the keys of each kind of layer, from tiles and feeds to polygons, heatmaps, vector tiles, queries for what is in view and identify. (26453 bytes) - [Translate the SDK](https://docs.mapcairn.com/guides/translate-the-sdk.md): Add a language to the interface, wire your own messages, and handle direction, plurals and fonts. (29704 bytes) - [Content Security Policy](https://docs.mapcairn.com/guides/content-security-policy.md): The Content-Security-Policy a page that hosts the SDK needs, directive by directive. (18981 bytes) - [Serving layers to MapCairn](https://docs.mapcairn.com/guides/serving-layers.md): Formats a server can offer as layers, what each costs the server, and worked definitions. (29179 bytes) - [Serving MapCairn from IIS](https://docs.mapcairn.com/guides/serving-from-iis.md): Serve a MapCairn build, or a page that hosts the SDK, from IIS with the right headers. (19497 bytes) - [The public API](https://docs.mapcairn.com/guides/public-api.md): What counts as public in the SDK packages, how it is reported and what is a breaking change. (23064 bytes) - [Capability matrix](https://docs.mapcairn.com/guides/capability-matrix.md): What the SDK does and does not do, row by row. (47465 bytes) - [Performance](https://docs.mapcairn.com/guides/performance.md): What the SDK loads and costs, measured, and how to keep a host fast. (10707 bytes) - [Machine-readable data](https://docs.mapcairn.com/guides/machine-readable-data.md): The JSON files the documentation site publishes for tools and agents (the page manifest, the API catalogue and the search index), with their fields and stability. (7615 bytes) - [Troubleshooting](https://docs.mapcairn.com/troubleshooting.md): The error messages the SDK throws and reports, what causes each, and how to fix it. (13863 bytes) - [API reference](https://docs.mapcairn.com/api.md): Every export of the MapCairn SDK packages, one page each, generated from the packages' TSDoc comments. (1223 bytes) - [@mapcairn/core](https://docs.mapcairn.com/api/core.md): Map interfaces, pure logic, basemaps and test fakes for MapCairn; no React, no browser globals. (119204 bytes) - [@mapcairn/react](https://docs.mapcairn.com/api/react.md): Generic React hooks for MapCairn applications. (1998 bytes) - [@mapcairn/theme](https://docs.mapcairn.com/api/theme.md): MapCairn's typed design tokens, light and dark themes, and contrast checks; plain CSS, no plugin needed. (5116 bytes) - [@mapcairn/map](https://docs.mapcairn.com/api/map.md): The accessible React map interface of MapCairn: map controls, panels, search, measure and draw tools. (39520 bytes) - [@mapcairn/adapter-maplibre](https://docs.mapcairn.com/api/adapter-maplibre.md): The MapLibre GL JS map adapter for MapCairn, and the styles that fit the engine into the map region. (847 bytes) - [@mapcairn/sdk](https://docs.mapcairn.com/api/sdk.md): One install and one import for the MapCairn SDK: core, map, react and theme, with the MapLibre adapter at a subpath. (1151 bytes) - [Architecture](https://docs.mapcairn.com/architecture.md): The layers, the ports, the map adapter, data layers and drawing, and how to add an adapter. (3353 bytes) - [Layers and dependency rules](https://docs.mapcairn.com/architecture/layers-and-dependency-rules.md): Which package may import which, and what each layer must not do. (5573 bytes) - [Building the SDK packages](https://docs.mapcairn.com/architecture/building-the-sdk-packages.md): How the six SDK packages are built, and in what order. (7199 bytes) - [Ports (part 1 of 2)](https://docs.mapcairn.com/architecture/ports-part-1.md): The interfaces the app depends on, each with a real adapter, a fake and a contract suite. (25576 bytes) - [Ports (part 2 of 2)](https://docs.mapcairn.com/architecture/ports-part-2.md): Ports, in Architecture. (21663 bytes) - [The map adapter](https://docs.mapcairn.com/architecture/the-map-adapter.md): MapLibre GL JS is the only map engine, and the ui never imports it. (37149 bytes) - [Data layers](https://docs.mapcairn.com/architecture/data-layers.md): How data layers are defined, loaded and shown on the map. (37453 bytes) - [Drawing](https://docs.mapcairn.com/architecture/drawing.md): How shapes are drawn, edited, imported, exported and shared. (11896 bytes) - [Adding an adapter](https://docs.mapcairn.com/architecture/adding-an-adapter.md): An adapter reaches the ui through the services. (1758 bytes) - [How tests substitute services](https://docs.mapcairn.com/architecture/how-tests-substitute-services.md): Unit tests wrap components in ServicesProvider with fakes. (2050 bytes) - [The reference host's pages](https://docs.mapcairn.com/architecture/the-reference-hosts-pages.md): The routes of the reference site. (4602 bytes) - [Design system](https://docs.mapcairn.com/design.md): The tokens, the layout slots and the accessibility contracts the interface keeps, and what the lint checks. (3252 bytes) - [How the CSS ships](https://docs.mapcairn.com/design/how-the-css-ships.md): How the CSS ships, in Design system. (4736 bytes) - [Living style guide](https://docs.mapcairn.com/design/living-style-guide.md): A developer page in the reference host that draws every token and primitive from the real code. (1104 bytes) - [Principles](https://docs.mapcairn.com/design/principles.md): The rules every part of the interface follows. (681 bytes) - [Tokens](https://docs.mapcairn.com/design/tokens.md): The colours, type, spacing and other values the interface is built from. (22879 bytes) - [Layout and slots](https://docs.mapcairn.com/design/layout-and-slots.md): Where each control sits on the screen, and which part of the code owns its place. (25022 bytes) - [Components and accessibility contracts (part 1 of 6)](https://docs.mapcairn.com/design/components-and-accessibility-contracts-part-1.md): What each component must do for names, roles, focus and keyboard use. (38862 bytes) - [Components and accessibility contracts (part 2 of 6)](https://docs.mapcairn.com/design/components-and-accessibility-contracts-part-2.md): Components and accessibility contracts, in Design system. (38253 bytes) - [Components and accessibility contracts (part 3 of 6)](https://docs.mapcairn.com/design/components-and-accessibility-contracts-part-3.md): Components and accessibility contracts, in Design system. (38254 bytes) - [Components and accessibility contracts (part 4 of 6)](https://docs.mapcairn.com/design/components-and-accessibility-contracts-part-4.md): Components and accessibility contracts, in Design system. (38253 bytes) - [Components and accessibility contracts (part 5 of 6)](https://docs.mapcairn.com/design/components-and-accessibility-contracts-part-5.md): Components and accessibility contracts, in Design system. (38253 bytes) - [Components and accessibility contracts (part 6 of 6)](https://docs.mapcairn.com/design/components-and-accessibility-contracts-part-6.md): Components and accessibility contracts, in Design system. (35403 bytes) - [The product page](https://docs.mapcairn.com/design/the-product-page.md): How the reference site's front page is written and laid out. (26782 bytes) - [Exempt surfaces](https://docs.mapcairn.com/design/exempt-surfaces.md): The few places that may hold raw values instead of tokens. (1916 bytes) - [What the lint checks, and where](https://docs.mapcairn.com/design/what-the-lint-checks-and-where.md): The design rules the lint enforces, and where each check lives. (8254 bytes) - [Design tokens, visually](https://docs.mapcairn.com/design/visual-tokens.md): The colour roles, type scale, spacing, radii and component specimens of the design system, drawn in the light and the dark theme from the SDK's own token values, with the contrast of each pair. (10200 bytes) - [Using the reference site](https://docs.mapcairn.com/guides/using-the-reference-site.md): What the reference site offers for language, search, saving the map, layers and drawing, and how each works from the keyboard and a pointer. (15823 bytes) - [Add to the reference site](https://docs.mapcairn.com/guides/add-to-the-reference-site.md): Contributor steps for adding a basemap, a data layer, a routing or suggestion provider or a language to the reference site in this repository. (19339 bytes) - [What the AGPL means for your project](https://docs.mapcairn.com/guides/licence.md): A plain-words guide to what MapCairn's AGPL-3.0-only licence asks of a project that uses the SDK. (10819 bytes) - [Roadmap](https://docs.mapcairn.com/roadmap.md): What MapCairn works on now, next and later, and how far each milestone has got. A priority, not a schedule. (3838 bytes) - [Changelog](https://docs.mapcairn.com/changelog.md): What changed in each release of the SDK packages, newest first, with a page for each release. (841 bytes) - [Release 0.2.0](https://docs.mapcairn.com/changelog/0.2.0.md): This release removes the data saver setting and makes the default basemap follow the theme. (5199 bytes) - [Release 0.1.0](https://docs.mapcairn.com/changelog/0.1.0.md): This is MapCairn's first release. (7797 bytes) - [Release 0.1.0-rc.3](https://docs.mapcairn.com/changelog/0.1.0-rc.3.md): This is the release where one install gets you a real map. (8593 bytes) - [Release 0.1.0-rc.2](https://docs.mapcairn.com/changelog/0.1.0-rc.2.md): This release candidate has the same code as 0.1.0-rc.1: nothing in @mapcairn/core, @mapcairn/map, @mapcairn/react or @mapcairn/theme has changed. (852 bytes) - [Release 0.1.0-rc.1](https://docs.mapcairn.com/changelog/0.1.0-rc.1.md): This is the first release of the four MapCairn SDK packages: @mapcairn/core, @mapcairn/map, @mapcairn/react and @mapcairn/theme. (8644 bytes)