global.d.ts 426 B

123456789101112131415161718192021
  1. export {};
  2. declare global {
  3. declare const Bridge: typeof import('./bridge').Bridge;
  4. interface Window {
  5. /* six-aio 设备注入 */
  6. bridge: InstanceType<typeof import('./bridge').Bridge>;
  7. }
  8. /**
  9. * Promise 扩展
  10. */
  11. interface PromiseConstructor {
  12. withResolvers<T>(): {
  13. promise: Promise<T>;
  14. resolve: (value: T | PromiseLike<T>) => void;
  15. reject: (reason?: any) => void;
  16. };
  17. }
  18. }