Skip to content

Release v3.6.0

Choose a tag to compare

@ansango ansango released this 29 Aug 08:01
· 8 commits to main since this release

What's Changed

⚡ Pluggable Cache Layer (client.cache / @ansango/lastfm-api/cache)

  • MemoryCacheStore for Node/Bun with configurable TTL and auto garbage collection.
  • StorageCacheStore for browser environments (localStorage / sessionStorage).
  • CacheManager with hierarchical TTL resolution (per-method, per-namespace, and default fallback).
  • Integrated caching in fetcher with cache bypass for authenticated and mutation requests.

📡 Real-Time Scrobble Watcher (client.watcher / @ansango/lastfm-api/watcher)

  • Fully typed TypedEventEmitter event bus.
  • ScrobbleWatcher polling engine emitting nowPlaying, nowPlayingEnd, scrobble, idle, and error events.
  • Lifecycle management with .start(), .stop(), .isActive(), and .forcePoll().

📦 Modular Subpath Exports & Zero Dependencies

  • Added @ansango/lastfm-api/cache, @ansango/lastfm-api/cache/schemas, @ansango/lastfm-api/watcher, and @ansango/lastfm-api/watcher/schemas to package.json.
  • Removed dotenv dependency in favor of native Node/Bun environment resolution.

Full Changelog: v3.5.0...v3.6.0