util.ts 272 B

123456789101112
  1. // weixin miniprogram
  2. // @ts-ignore
  3. const isWx = (typeof wx === 'object') && (typeof wx.getSystemInfoSync === 'function');
  4. // ant miniprogram
  5. // @ts-ignore
  6. const isMy = (typeof my === 'object') && (typeof my.getSystemInfoSync === 'function');
  7. export {
  8. isWx,
  9. isMy,
  10. }