chromium/third_party/blink/renderer/core/scheduler/window_idle_tasks.idl

// Copyright 2023 The Chromium Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.

// Cooperative Scheduling of Background Tasks
// https://www.w3.org/TR/requestidlecallback/#window_extensions
[
  ImplementedAs=WindowIdleTasks
] partial interface Window {
  [Measure] long requestIdleCallback(IdleRequestCallback callback, optional IdleRequestOptions options = {});
  void cancelIdleCallback(long handle);
};