UNPKG

@adyen/adyen-platform-experience-web

Version:

![Platform Experience header](https://github.com/Adyen/adyen-platform-experience-web/assets/7926613/18094965-9e01-450e-8dc9-ea84e6b22c2b)

25 lines (24 loc) 773 B
import { createWatchlist as i } from "../../reactive/watchlist/main.js"; import { createInterval as n } from "../interval/main.js"; import { struct as a } from "../../../utils/struct/main.js"; import { enumerable as r } from "../../../utils/struct/property.js"; const f = (() => { let e; const { cancelSubscriptions: o, requestNotification: c, subscribe: s, on: t } = i({ // Use wrapper function instead of direct reference to `Date.now`, // otherwise, tests will fail since `Date.now` won't be mocked now: () => Date.now() }); return t.resume = () => { e = n(c, 1e3, !1); }, t.idle = () => { e == null || e.cancel(), e = void 0; }, a({ cancelSubscriptions: r(o), subscribe: r(s) }); })(); export { f as clock, f as default };