Package Exports
- lanesdotdev-analytics
- lanesdotdev-analytics/dist/index.js
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (lanesdotdev-analytics) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
Lanes.dev Analytics
A lightweight, privacy-friendly analytics package for tracking website visitors.
Get your api key from https://lanes.dev after signing up and creating your free project (no credit card required)
Installation
Option 1: NPM (Recommended)
npm i lanesdotdev-analytics
# or
yarn add lanesdotdev-analytics
# or
pnpm add lanesdotdev-analyticsOption 2: Script Tag
For static websites or quick setup:
<script type="module">
import { Analytics } from 'https://unpkg.com/lanesdotdev-analytics@0.1.2/dist/index.js';
new Analytics({
apiKey: 'your-api-key'
});
</script>Usage
import { Analytics } from 'lanesdotdev-analytics';
// Initialize analytics
const analytics = new Analytics({
apiKey: 'your-api-key'
});The snippet will automatically:
- Track page views
- Support Single Page Applications
- Work in development and production
Features
- 🔒 Privacy-friendly tracking
- 🚀 Zero configuration
- 📊 Real-time analytics
- 🌐 SPA support
- ⚡ Lightweight bundle
Development
# Install dependencies
pnpm install
# Build
pnpm build
# Development mode
pnpm devLicense
MIT