W3cubDocs

/Dart 2

requestIdleCallback method

int requestIdleCallback (IdleRequestCallback callback, [ Map options ])

Implementation

int requestIdleCallback(IdleRequestCallback callback, [Map options]) {
  if (options != null) {
    var callback_1 = convertDartClosureToJS(callback, 1);
    var options_2 = convertDartToNative_Dictionary(options);
    return _requestIdleCallback_1(callback_1, options_2);
  }
  var callback_1 = convertDartClosureToJS(callback, 1);
  return _requestIdleCallback_2(callback_1);
}

© 2012 the Dart project authors
Licensed under the Creative Commons Attribution-ShareAlike License v4.0.
https://api.dart.dev/stable/2.5.0/dart-html/Window/requestIdleCallback.html