Skip to content

Releases: steelbreeze/pivot

Performance

30 Sep 12:02
Compare
Choose a tag to compare

Remove iterating the same array twice in the pivot function

API improvements & documentation

15 Jan 09:10
Compare
Choose a tag to compare

Pivot is available from Skypack and can be found here: https://cdn.skypack.dev/@steelbreeze/pivot

API improvements

The API has seen incremental changes in 4.2 and now 4.3 releases. The following are highlights and breaking changes:

  • The Predicate type has been renamed Criteria as this more accurately reflects its use in Dimension construction.
  • The map function has been renamed aggregate as it does not just map the data, it also flattens the data by one dimension.
  • The distinct function has been removed, as it is not strictly required, it was just provided as a utility and can easily be replicated with the code fragment below:
function distinct<TValue>(value: TValue, index: number, source: Array<TValue>): boolean {
	return source.indexOf(value) === index;
}

Documentation

All the function call documentation has now been tidied and has example code fragments. Documentation can be found here: https://steelbreeze.net/pivot/api/v4/

Tidy pivot function API and implementation

13 Jan 18:01
Compare
Choose a tag to compare

Refactored the API declaration and implementation of the pivot function for clearer and simpler use and maintenance.

Also simplified the implementations of the helper functions.

More cube creation performance

06 Jun 16:51
Compare
Choose a tag to compare

Remove the last remaining map call in pivotImplementation

Query performance

06 Jun 14:33
Compare
Choose a tag to compare

Just like the cube creation performance improvements, similar techniques applied to cube queries.

Yet more performance

01 May 09:26
Compare
Choose a tag to compare

Manual loop optimisation; changed:

for (var di = 0; di < first.length; ++di) {

to

for (var di = 0, dl = first.length; di < dl; ++di) {

Which makes a surprisingly large improvement.

A little more performance

30 Apr 12:09
Compare
Choose a tag to compare
4.1.8

Better typing in test

Start testing

28 Apr 10:07
Compare
Choose a tag to compare

Restructured non-core source code and started on a test suite (with a view to having coverage in place in a later release)

Minor refactor

23 Apr 02:13
Compare
Choose a tag to compare

The prior move to the partition function renders the copying of the source data redundant in the implementation of the pivot function; the latter can now just become an alias with the desired external API applied.

Minor performance tweak

22 Apr 12:07
Compare
Choose a tag to compare

Use var in place of let in for loops as this yields better performance in large data sets.