@undp-data/style-viewer
This component is a simple maplibre style viewer.
Usage
<script lang="ts">
import { StyleViewer } from '@undp-data/style-viewer';
import { PUBLIC_AZURE_URL } from '$env/static/public';
</script>
<div>
<StyleViewer azureUrl={PUBLIC_AZURE_URL} />
</div>
It requires to set Azure container URL which stores admin data. Please set it in .env
create svelte
Everything you need to build a Svelte project, powered by create-svelte
.
Creating a project
If you're seeing this, you've probably already done this step. Congrats!
npm create svelte@latest
npm create svelte@latest my-app
Developing
Once you've created a project and installed dependencies with npm install
(or pnpm install
or yarn
), start a development server:
npm run dev
npm run dev -- --open
Building
To create a production version of your app:
npm run build
You can preview the production build with npm run preview
.
To deploy your app, you may need to install an adapter for your target environment.