{"_id":"streak-daily-lib","name":"streak-daily-lib","dist-tags":{"latest":"1.0.0"},"versions":{"1.0.0":{"name":"streak-daily-lib","version":"1.0.0","description":"Dependency-free calendar-day bucketing and streak math primitives, with an optional Node-only on-disk store. Helper for svelte-insights-hydration.","type":"module","license":"MIT","exports":{".":{"types":"./index.d.ts","default":"./index.mjs"},"./store":{"types":"./store.d.ts","default":"./store.mjs"}},"keywords":["streak","calendar","day","analytics"],"types":"./index.d.ts","_id":"streak-daily-lib@1.0.0","_nodeVersion":"24.15.0","_npmVersion":"11.12.1","dist":{"integrity":"sha512-xaTiQk/qCOK2aTF/0jZcp3/6QwIS7eevc3HIC+nW0QTLE3PedKBCYMEPyrG0FFGQNfmhnreivzTggHQxmB6/8Q==","shasum":"7db7d1a116631bcb362f7715d37d0f0a6aed8e87","tarball":"https://registry.npmjs.org/streak-daily-lib/-/streak-daily-lib-1.0.0.tgz","fileCount":7,"unpackedSize":10135,"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEQCIFFGKRAUxnEfKakFOYRBDymdIgtAfbKQNoXNfXfQe/HmAiA0YDToemrMbHOR2dliW2g0M1VYm1NpmAtlXXUtNDy6lg=="}]},"_npmUser":{"name":"taipen_chat","email":"taipen_chat@proton.me"},"directories":{},"maintainers":[{"name":"taipen_chat","email":"taipen_chat@proton.me"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/streak-daily-lib_1.0.0_1784982554780_0.06712978215647736"},"_hasShrinkwrap":false}},"time":{"created":"2026-07-25T12:29:14.722Z","1.0.0":"2026-07-25T12:29:14.934Z","modified":"2026-07-25T12:29:15.145Z"},"maintainers":[{"name":"taipen_chat","email":"taipen_chat@proton.me"}],"description":"Dependency-free calendar-day bucketing and streak math primitives, with an optional Node-only on-disk store. Helper for svelte-insights-hydration.","keywords":["streak","calendar","day","analytics"],"license":"MIT","readme":"# streak-daily-lib\n\nDependency-free calendar-day and streak-math primitives. This is the **helper**\npackage behind [`svelte-insights-hydration`](../svelte-insights-hydration); it is not meant to\nbe imported directly from application code.\n\n## API\n\n```js\nimport { dayKey, addDays, dayDiff, bucketByDay, qualifyingDayKeys } from 'streak-daily-lib';\nimport { store } from 'streak-daily-lib/store'; // Node-only\n```\n\n- `dayKey(date, timeZone?)` → `\"YYYY-MM-DD\"`\n- `addDays(key, n)` → shifted day key\n- `dayDiff(aKey, bKey)` → whole-day difference\n- `bucketByDay(entries, timeZone?)` → `Map<dayKey, total>`\n- `qualifyingDayKeys(entries, goal, timeZone?)` → sorted day keys meeting the goal\n\n","readmeFilename":"README.md","_rev":"1-77900db621b484056c215baf052b7d6f"}