aboutsummaryrefslogtreecommitdiffstats
path: root/node_modules/rxjs/src/internal/scheduler/performanceTimestampProvider.ts
blob: 873e71b8433e1efae702e0e13fa60148d6470d95 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
import { TimestampProvider } from '../types';

interface PerformanceTimestampProvider extends TimestampProvider {
  delegate: TimestampProvider | undefined;
}

export const performanceTimestampProvider: PerformanceTimestampProvider = {
  now() {
    // Use the variable rather than `this` so that the function can be called
    // without being bound to the provider.
    return (performanceTimestampProvider.delegate || performance).now();
  },
  delegate: undefined,
};
send patches to the email below
yukais@pinapelz.com
include the subject [PATCH repo_name]
pinapelz.com
homepage