Skip to content

Commit

Permalink
Preserve the old options.debounceRendering instead of renaming it t…
Browse files Browse the repository at this point in the history
…o `Component.debounce`
  • Loading branch information
developit committed Mar 4, 2019
1 parent d5d42d7 commit 9579062
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/component.js
@@ -1,5 +1,6 @@
import { assign } from './util';
import { diff, commitRoot } from './diff/index';
import options from './options';

/**
* Base Component class. Provides `setState()` and `forceUpdate()`, which
Expand Down Expand Up @@ -123,7 +124,7 @@ const defer = typeof Promise=='function' ? Promise.resolve().then.bind(Promise.r
*/
export function enqueueRender(c) {
if (!c._dirty && (c._dirty = true) && q.push(c) === 1) {
(Component.debounce || defer)(process);
(options.debounceRendering || defer)(process);
}
}

Expand Down

0 comments on commit 9579062

Please sign in to comment.