@mappedin/viewer
TypeScript icon, indicating that this package has built-in type declarations

0.21.2 • Public • Published

Mappedin Viewer

A lightweight indoor map application with first class support for maps made in Mappedin Maker.

Getting Started

HTML

Add a <div> element to your website with the id #viewer-app-root. The map will be rendered into this element.

<body>
	<div id="viewer-app-root"></div>
</body>

Then, add the following snippet somewhere in your website.

<script type="module">
	import start from 'https://cdn.jsdelivr.net/npm/@mappedin/viewer@latest/dist/index.js';
	start();
</script>

Package Manager

Install the package with the package manager of your choice.

# npm
npm install @mappedin/viewer

# yarn
yarn add @mappedin/viewer

#pnpm
pnpm i @mappedin/viewer

Pointing at a public Mappedin Maker venue

Import and run the default start method. The ID of the Maker Venue will be parsed from the URL.

import start from '@mappedin/viewer';

start({
	root: document.getElementById('my-element')!,
});

Pointing at local MVF

Import and run the startWithLocalData method.

import { startWithLocalData } from '@mappedin/viewer';

startWithLocalData({
	data: myParsedMVF,
});

Readme

Keywords

none

Package Sidebar

Install

npm i @mappedin/viewer

Weekly Downloads

694

Version

0.21.2

License

UNLICENSED

Unpacked Size

8.83 MB

Total Files

215

Last publish

Collaborators

  • mappedin-ops
  • mappedin-engineering