UNPKG

768 BJavaScriptView Raw
1/* eslint-disable */
2
3// This file includes experimental React APIs exported from the "scheduler"
4// npm package. Despite being explicitely marked as unstable some libraries
5// already make use of them. This file is not a full replacement for the
6// scheduler package, but includes the necessary shims to make those libraries
7// work with Preact.
8
9export var unstable_ImmediatePriority = 1;
10export var unstable_UserBlockingPriority = 2;
11export var unstable_NormalPriority = 3;
12export var unstable_LowPriority = 4;
13export var unstable_IdlePriority = 5;
14
15/**
16 * @param {number} priority
17 * @param {() => void} callback
18 */
19export function unstable_runWithPriority(priority, callback) {
20 return callback();
21}
22
23export var unstable_now = performance.now.bind(performance);