Mastering Immutable.js
上QQ阅读APP看书,第一时间看更新

What are we comparing?

There's no point in comparing a library such as Immutable.js with something that has no notion of functional programming or immutability. For instance, Angular is a framework for building applications, and observing changes in state is a core pattern. This is something that Immutable.js doesn't do. Comparing Immutable.js with something such as React doesn't make much sense either. Despite the fact that React honors concepts such as avoiding side-effects, we wouldn't be comparing apples with apples, as they do different things at different levels of abstraction.

Some criteria that you would use to compare Immutable.js with other libraries include the following:

  • Is it a low-level library?
  • Does it support the notion of immutability?
  • Does it have the concept of collections?
  • How large is the API compared with that of Immutable.js?
  • How efficiently can it handle immutable data?