Home
Softono
btcmap.org

btcmap.org

Open source Svelte
67
Stars
34
Forks
50
Issues
6
Watchers
1 week
Last Commit

About btcmap.org

Free and open source bitcoin map web application

Platforms

Web Self-hosted

Languages

Svelte

BTC Map Web App

Netlify Status

Getting started

  1. git clone\ to clone the repo and cd into the directory
  2. Enable Corepack (if needed)\ If pnpm command is not found, run: corepack enable
  3. pnpm install\ to install the packages
  4. pnpm dev\ will open the app on: http://localhost:5000

Check your changes before commit/pushing

  • pnpm run format:fix
  • pnpm run lint
  • pnpm run check
  • pnpm run typecheck
  • pnpm run test --run

Local API development

To test the frontend against a local btcmap-api instance:

  1. Start the API: cd btcmap-api && cargo run (binds to 127.0.0.1:8000)
  2. Add to your .env — pick one:
    • VITE_API_BASE_URL=/btcmap-api-proxy — routes through the Vite dev proxy (avoids CORS; works for client-side calls and SSR load functions that use SvelteKit's event.fetch)
    • VITE_API_BASE_URL=http://127.0.0.1:8000 — direct; works everywhere including SSR axios calls, but requires the API to send CORS headers
  3. Start the frontend: pnpm dev

Remove or comment out the env var to switch back to the production API.

Build project

  1. Create .env
    Copy .env.example and save as .env
  2. pnpm build

NOTE: BTC Map uses Node 22 LTS. If you have mise, run mise install in the repo root to switch to the correct version. This project uses Corepack (bundled with Node 22) to manage pnpm automatically.

Icons

  • Iconify: for general material/fontawesome icons via Icon.svelte
  • Custom icons (socials, apps, mobile-nav): imported as raw SVGs in src/lib/icons/ via wrapper components (IconSocials.svelte, IconApps.svelte, IconMobileNav.svelte)

E2E tests

Install

  pnpm playwright install

Run tests

  pnpm playwright test
    Runs the end-to-end tests.

  pnpm playwright test --ui
    Starts the interactive UI mode.

  pnpm playwright test --project=chromium
    Runs the tests only on Desktop Chrome.

  pnpm playwright test example
    Runs the tests in a specific file.

  pnpm playwright test --debug
    Runs the tests in debug mode.

PWA

This website is a progressive web app, meaning you can install it on your mobile device and use it like a native application. Just look for the Add to home screen or Install option in your browser while visiting btcmap.org.

Embedding

For information on how to embed the BTC Map web map onto your own website or application please reference our Wiki.


Attributions

Thanks to:

Base map tiles

Icons

Tagger profile badges by AndrejCibik

Satoshi nakamoto icons created by Vitaly Gorbachev - Flaticon


Untitled