如何将 Apple Pay JS 与 angular 集成

问题描述

我正在考虑将 Apple Pay 集成到我的结帐页面中。如何通过验证 ApplePaySession 类是否存在来检查浏览器中 Apple Pay JS API 是否可用。

当我给出条件时,

if (window.ApplePaySession && ApplePaySession.canMakePayments()){}

显示错误,即; "Property 'ApplePaySession' does not exist on type 'Window & typeof globalThis'"

解决方法

暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!

如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。

小编邮箱:dio#foxmail.com (将#修改为@)