mirror of
https://github.com/grafana/grafana.git
synced 2024-11-25 10:20:29 -06:00
1d689888b0
* Updated package json but not updated source files * Update eslint plugin * updated files
18 lines
422 B
TypeScript
18 lines
422 B
TypeScript
declare var global: NodeJS.Global;
|
|
|
|
(global as any).requestAnimationFrame = (callback: any) => {
|
|
setTimeout(callback, 0);
|
|
};
|
|
|
|
(Promise.prototype as any).finally = function (onFinally: any) {
|
|
return this.then(
|
|
/* onFulfilled */
|
|
(res: any) => Promise.resolve(onFinally()).then(() => res),
|
|
/* onRejected */
|
|
(err: any) =>
|
|
Promise.resolve(onFinally()).then(() => {
|
|
throw err;
|
|
})
|
|
);
|
|
};
|