Bundle Size
Size of each distribution format and tree-shaking capabilities.
The production bundle (minified JS + CSS) weighs ~42 KB gzipped. Borda has no runtime dependencies and loads nothing beyond the assets you provide.
Distribution files
Each module format ships in two variants: a minified production build and an unminified development build with readable code and comments.
| File | Format | Raw | Gzip |
|---|---|---|---|
borda.min.es.js | ES Module | 134.61 KB | 37.49 KB |
borda.min.umd.js | UMD | 139.65 KB | 37.89 KB |
borda.min.cjs.js | CommonJS | 134.95 KB | 37.53 KB |
borda.es.js | ES Module | 318.88 KB | 76.31 KB |
borda.umd.js | UMD | 330.01 KB | 77.16 KB |
borda.cjs.js | CommonJS | 320.07 KB | 76.46 KB |
borda.css | CSS | 28.03 KB | 4.12 KB |
Tree-shaking
The ES Module build supports tree-shaking. If your bundler detects unused exports, they are removed from the final output. In practice, this means projects that only use a subset of Borda's API can produce smaller bundles than the numbers above.
The numbers above are for the full library with all components. Tree-shaking with ES Module imports can reduce the JavaScript payload for projects that only use a subset of features.
What's included
The bundle contains:
- Svelte 5 runtime (minimal, compiled away in most cases)
- Tour controller and step navigation logic
- Spotlight overlay with SVG cutout
- Tooltip positioning engine with auto-flip
- Keyboard navigation handler
- Touch swipe navigation handler
- Event bus
- Responsive breakpoint system
- Scroll animation engine
- Skip persistence layer
- All UI components (buttons, progress, image, close button)