Skip to content

Releases: inorganik/countUp.js

2.8.0

25 Aug 16:56
Compare
Choose a tag to compare

Added onStartCallback option, useful for when scroll spy is enabled, thanks to @cherrol !

2.7.0

28 Jun 17:10
Compare
Choose a tag to compare

Reverted change which made "main" in package.json point to the module file, instead of the umd file. It now points again at the umd file.

2.6.2

01 May 20:48
Compare
Choose a tag to compare

When revamping the build, I tried to resolve a rollup warning that had been occurring on the build for a long time:

"(!) `this` has been rewritten to `undefined`

It occurs because of typescript's Object.assign polyfill, which uses this on the global scope. If you set context: 'window' in the rollup config, it will silence the warning, but it will cause issues if CountUp is not run in the browser. Allowing rollup to rewrite this to undefined on just the global scope is harmless and doesn't break anything, so I reverted the change.

2.6.1

30 Apr 14:55
9c2f33c
Compare
Choose a tag to compare

This release doesn't change the CountUp code at all, just the distribution files - The requestAnimationFrame polyfill is no longer bundled with CountUp but served separately. The other files in dist remain the same. More details in the PR: #311

2.6.0

13 Mar 22:12
49e46aa
Compare
Choose a tag to compare

Support animation plugins: A plugin is a class instance or object passed in options for the plugin param that implements a render method:

export declare interface CountUpPlugin {
  render(elem: HTMLElement, formatted: string): void;
}

The plugin's render method will be called on each frame to display the formatted value instead of CountUp's.

v2.5.0

01 Mar 20:43
c12680a
Compare
Choose a tag to compare

Added new option, onCompleteCallback which gets called when the animation completes. You can still pass a callback to the start method, and it will override whatever is passed in the options.

2.4.2

28 Jan 17:58
Compare
Choose a tag to compare

Make it so when scroll spy is enabled, and scrollSpyOnce is false, CountUp will re-animate when scrolling up, as well as down, thanks to @paidge

2.4.1

24 Jan 13:14
27e537e
Compare
Choose a tag to compare
  • Added Indian separators option useIndianSeparators which will format a number like "1,00,000" instead of "100,000"
  • Added null check in printValue method to potentially fix react issue

2.3.2

08 Jul 12:43
1e87b68
Compare
Choose a tag to compare

Fixes #287 which was a bug where, when using smart easing and counting down, the animation would take longer than configured. It also fixed an issue which caused 2 easing cycles to run for the same scenario.

2.3.1

29 Jun 19:51
Compare
Choose a tag to compare

Fix window check for SSR, thanks to @johakr