Repository navigation
@tanstack/db-ivm@1.0.0-rc.1.5
Pre-releasePatch Changes
-
Avoid structural hashing on small
Indexbuckets. A bucket of up to two values compares them withequalHashValuesand promotes to a hashed map at the third value, which removes redundant hashing of large rows during incremental join updates.equalHashValueslists an object's keys natively and skips type tests for plain arrays and plain objects, andjoinreads each key's rows as an array instead of through nested generators. (#2488)Index, and sojoinandreduce, no longer merges two distinct values whose 32-bit hashes collide. AnIndex.addValuethat throws leaves the entries and presence of its key unchanged. A cyclic or very deep value is rejected when a bucket first hashes it, at its third distinct value, where it was rejected at the second before.equalHashValuescompares deeply nested values without overflowing the call stack.Two separate
RegExpvalues with aNaNlastIndexnow stay distinct in anIndex, asequalHashValuesalready defined them. They merged before because their hashes are equal.Operators no longer take or store an
id: theOperator,UnaryOperator, andBinaryOperatorconstructors lose their first parameter, andD2.getNextOperatorIdis removed. Nothing read the id.structuralIdentitygives a RegExp whoselastIndexis not a primitive no identity, andhashrefuses a RegExp whoselastIndexis a plain object with a TypeError, sogroupByno longer merges two such RegExps that D2 compares as different. The hash stream no longer writes a marker fornull, so digest values differ from earlier versions; D2 value identity is unchanged.MultiSet.consolidatekeeps two records of different structure apart when their digests collide.An Effect whose query graph step throws now reports the error once through
onSourceError(orconsole.errorwithout a handler) and disposes, as a live query does, instead of rerunning the graph over partly applied state. -
Reduce the initial JavaScript download for eager React and Query DB apps. Load on-demand and persisted Query sync as needed. Preserve refetch settlement during startup and support built-in functions in manually constructed query expressions. (#2500)