@@ -17,19 +17,19 @@ function flushCallbacks () {
17
17
}
18
18
}
19
19
20
- // Here we have async deferring wrappers using both micro and macro tasks.
21
- // In < 2.4 we used micro tasks everywhere, but there are some scenarios where
22
- // micro tasks have too high a priority and fires in between supposedly
20
+ // Here we have async deferring wrappers using both microtasks and ( macro) tasks.
21
+ // In < 2.4 we used microtasks everywhere, but there are some scenarios where
22
+ // microtasks have too high a priority and fire in between supposedly
23
23
// sequential events (e.g. #4521, #6690) or even between bubbling of the same
24
- // event (#6566). However, using macro tasks everywhere also has subtle problems
24
+ // event (#6566). However, using ( macro) tasks everywhere also has subtle problems
25
25
// when state is changed right before repaint (e.g. #6813, out-in transitions).
26
- // Here we use micro task by default, but expose a way to force macro task when
26
+ // Here we use microtask by default, but expose a way to force ( macro) task when
27
27
// needed (e.g. in event handlers attached by v-on).
28
28
let microTimerFunc
29
29
let macroTimerFunc
30
30
let useMacroTask = false
31
31
32
- // Determine (macro) Task defer implementation.
32
+ // Determine (macro) task defer implementation.
33
33
// Technically setImmediate should be the ideal choice, but it's only available
34
34
// in IE. The only polyfill that consistently queues the callback after all DOM
35
35
// events triggered in the same loop is by using MessageChannel.
@@ -56,7 +56,7 @@ if (typeof setImmediate !== 'undefined' && isNative(setImmediate)) {
56
56
}
57
57
}
58
58
59
- // Determine MicroTask defer implementation.
59
+ // Determine microtask defer implementation.
60
60
/* istanbul ignore next, $flow-disable-line */
61
61
if ( typeof Promise !== 'undefined' && isNative ( Promise ) ) {
62
62
const p = Promise . resolve ( )
@@ -76,7 +76,7 @@ if (typeof Promise !== 'undefined' && isNative(Promise)) {
76
76
77
77
/**
78
78
* Wrap a function so that if any code inside triggers state change,
79
- * the changes are queued using a Task instead of a MicroTask .
79
+ * the changes are queued using a (macro) task instead of a microtask .
80
80
*/
81
81
export function withMacroTask ( fn : Function ) : Function {
82
82
return fn . _withTask || ( fn . _withTask = function ( ) {
0 commit comments