Releases: immutable-js/immutable-js
v4.0.0-rc.4
v4.0.0-rc.3
This RC is now relicensed as MIT (#1320)
BREAKING:
-
Remove Seq.of() (#1311, #1310 )
This method has been removed since it cannot be correctly typed. It's recommended to convert
Seq.of(1, 2, 3)
toSeq([1, 2, 3])
.
New:
- Support for Transducers! (ee9c68f)
- A new method,
zipAll()
(#1195) - Considerably improved Record typing (#1193, #1276)
- Bundle and distribute an "es module" so Webpack and Rollup can use tree-shaking for smaller builds (#1204)
- Warn instead of throw when
getIn()
has a bad path (668f223) - Improved TypeScript types for
zip()
. (#1258) - Improved TypeScript types for
has()
. (#1232) - Support typescript strictNullChecks (#1168)
Fixed:
- Updated Flow types to work with 0.55 and higher (#1312)
- Updated TypeScript types to work with v2.4 and higher (#1285)
- Do not throw from hasIn (#1319)
- Long hash codes no longer cause an infinite loop (#1175)
slice()
which should return an empty set could return a full set or vice versa (#1245, #1287)- Ensure empty slices do not throw when iterated (#1220)
- Error during equals check on Record with undefined or null (#1208)
- Fixes missing size property in flow types. (#1173)
- Fix size of count() after filtering or flattening (#1171)
v4.0.0-rc.2
v4.0.0-rc.1
This is a pre-release version of Immutable.js. Please try it at your own risk and report any issues you encounter so an official release can be shipped with great confidence.
As a pre-release, this changelog doesn't contain everything that has changed. Take a look at the commit log for a complete view, and expect a more thorough changelog for the official release.
Breaking Changes
-
The
Iterable
class has been renamed toCollection
, andisIterable()
has been renamed toisCollection()
. Aliases with the existing names exist to make transitioning code easier. -
The "predicate" functions,
isCollection
,isKeyed
,isIndexed
,isAssociative
have been moved fromIterable.
to the top level exports. -
Record is no longer an Immutable Collection type.
- Now
isCollection(myRecord)
returnsfalse
instead oftrue
. - The sequence API (such as
map
,filter
,forEach
) no longer exist on Records. delete()
andclear()
no longer exist on Records.
- Now
-
The
toJSON()
method is now a shallow conversion (previously it was an alias fortoJS()
, which remains a deep conversion). -
Some minor implementation details have changed, which may require updates to libraries which deeply integrate with Immutable.js's private APIs.
-
The Cursor API is officially deprecated. Use immutable-cursor instead.
New Stuff!
-
A new predicate function
isValueObject()
helps to detect objects which implementequals()
andhashCode()
, and type definitions now define the interfaceValueObject
which you can implement in your own code to create objects which behave as values and can be keys in Maps or entries in Sets. -
The Flowtype and TypeScript type definitions have been completely rewritten with much higher quality and accuracy, taking advantage of the latest features from both amazing tools.
-
Using
fromJS()
with a "reviver" function now provides access to the key path to each translated value. (#1118)
Bug fixes
- Numerous bug fixes have gone into this release.
v3.8.1
Minor touch ups discovered after the last release, plus a few more bug fixes! Plus, you can now contribute to immutable-js using the latest version of node.
New:
- The methods
keyOf
,findKey
,lastKeyOf
, andfindLastKey
were moved from KeyedIterable to Iterable, so they may be also used on Lists and Sets. (#740)
Fixes:
- Some issues with the flow definitions have been polished out thanks to @marudor. (#840, #841, #845)
- Collections which contain
Symbol
keys or values can now be stringified. (#620) - Negative indexing into the keySeq of an IndexedIterable returns correct results. (#811)
- Can use the value
Infinity
as a key in a Collection without crashing. (#797)
v3.8.0
Whoa, a new version of Immutable! The big news is that we now export types for both Flow and TypeScript in the npm module! Also that pesky length
warning has finally been fully removed. There are also a good amount of small bug fixes and performance improvements. Finally, the API docs have been improved greatly! Check it out http://facebook.github.io/immutable-js/docs/.
A huge huge thanks to everyone in the community for contributing these improvements. The large majority of work cited below is community contributions.
New:
- Now exports Flow types (#805)
- Now exports
typings
for TypeScript use. (#808) - Cursor TypeScript definitions (#765)
- No longer warns when accessing
length
property of a collection. (88f880f) Map.of()
takes key, value interleaved pairs (#727)findEntry
andfindLastEntry
now respectnotSetValue
argument (#822)
Fixes:
3.7.6
A few minor bug fixes:
- Fixed issue where
lastIndexOf
did not always return the correct value #703 mergeDeep
now has more opportunities to for the "return self" optimization, saving memory #690- The TypeScript .d.ts file now aligns with the outputted file for the variations of Immutable Iterables. #647
- Ensure behavior for
slice(0, NaN)
is equivalent to that of JS Array #623 - Ensure ES6 Symbol can be properly hashed #579
And a new API method:
myList.insert()
#402
3.7.5
Many stability improvements thanks to excellent community submitted fixes.
New:
- Cursor can now
set(value)
#516 to replace the value at the cursor.
Fixes:
- Ensure all tests pass in node v0.12
- All operations that accept indicies now use ECMA's algorithm for converting input to integers when possible. #545 #598
- Fix issue where slice/splice with non-number arguments could result in infinite recursion. #511
- Clearer documentation regarding creating Map from JS Obj #589
- Immutable now exported as a TypeScript module #567
- Trailing commas causing issues in IE8 #510
- Fix memory leak from setSize() and slice() #540
- Union and Merge of Map or Set always favors the type of the left hand side #515