amp-html - AMP JS 更新是否破坏了 ON 属性?
问题描述
直到今天,我们新的 AMP HTML 网站的本地开发实例进展顺利。我们的 Firebase 实例最后一次更新是 5 月 23 日,但今天我们的本地站点和托管站点都存在 ON 属性问题:
on="tap:AMP.navigateTo(url='https://my_url')"
不会触发具有 ON 属性的按钮元素,错误是:
Uncaught TypeError: Cannot read property 'length' of undefined
at Ga (string.js:79)
at nk.f.handleAmpTarget (resources-impl.js:1513)
at Kg (v0.js:158)
at l (v0.js:157)
at v0.js:157
at Array.forEach (<anonymous>)
at Jg (v0.js:157)
at Fg.f.trigger (event-helper.js:66)
at HTMLDocument.<anonymous> (priority-queue.js:99)
我是在等待 Google 的 AMP 团队解决这个问题,还是我能做些什么?
解决方案
已确认 AMP JS 的更改破坏了导航功能。这已得到修复。 https://github.com/ampproject/amphtml/issues/15695
推荐阅读
- php - 执行 MySQL 查询时,charset 如何影响 php?
- python - 将列表中的字符串项匹配并替换为另一个列表中的字符串项
- python - 如何使用 selenium 和 python 点击动态 Twitter 关注按钮?
- gitlab - 使用 gitlab runner 挂载 hostpah 卷的正确方法是什么?
- mysql - XAMPP 上的 Symfony 4 - make:migration 不起作用,找不到驱动程序
- excel-formula - 如何根据多行中的条件对多个单元格中的值求和?
- google-apps-script - 将文件从网络上传到 Google 云端硬盘
- c - #define 中的换行符和单双引号
- python - 使用 slice 来迭代列表
- angular - 如何在 Input Angular Decorator 中使用 Observable?