Skip to content

Releases: bvaughn/suspense

0.0.43

28 Jun 14:38
Compare
Choose a tag to compare
  • Fix potential update loop in useImperativeCacheValue from nested object properties

0.0.42

27 Jun 15:48
Compare
Choose a tag to compare
  • Fix potential update loop in useImperativeCacheValue

0.0.41

27 Jun 14:09
Compare
Choose a tag to compare
  • useImperativeCacheValue supports async mutations made with useCacheMutation; (specifically, it returns a previously resolved value when status is pending due to a mutation).

0.0.40

24 Jun 20:26
Compare
Choose a tag to compare
  • Added opt-in debug logging per cache (enableDebugLogging config) as well as globally (enableDebugLogging export) for development builds.
  • Add (DEV-only) warning to createIntervalCache and createStreamingCache for non-unique cache keys– specifically warning about the key containing an Object case as a string.

Debug logging

In development mode, "suspense" can be configured to log timing information. Logging can be enabled/disabled per cache:

import { createCache } from "suspense";

// Cache can be configured during initialization
const cache = createCache({
  debugLogging: true,
  load,
});

// They can also be turned on/off later
cache.disableDebugLogging();
cache.enableDebugLogging();

It can also be done globally (for all caches).

import { disableDebugLogging, enableDebugLogging } from "suspense";

// Turns debug logging on for all caches
enableDebugLogging();

// Turns debug logging off for all caches
disableDebugLogging();

0.0.39

09 Jun 21:54
Compare
Choose a tag to compare
  • Add (DEV-only) warning for non-unique cache keys– specifically warning about the key containing an Object case as a string.

0.0.38

29 May 21:07
Compare
Choose a tag to compare
  • 32: Build release bundle with Preconstruct

0.0.37

25 Apr 20:42
71e5c07
Compare
Choose a tag to compare
  • createIntervalCache edge case bug fix caught by enabling TSC --noUncheckedIndexedAccess flag.

0.0.36

25 Apr 15:08
0e35897
Compare
Choose a tag to compare
  • createIntervalCache removes comparePoints param (as it is no longer needed).

0.0.35

25 Apr 14:29
Compare
Choose a tag to compare
  • createIntervalCache supports partial results via new options parameter options.returnAsPartial(resultsArray).
  • createIntervalCache methods getValue and getStatus better handle sub-regions of already-loaded intervals.
  • ⚠️ createIntervalCache no longer supports string points, only number and BigInt types are supported.

0.0.34

20 Apr 16:33
Compare
Choose a tag to compare
  • createExternallyManagedCache cache updated to support caching errors (via cacheError method); cache method renamed to cacheValue to differentiate.