这是一个创建于 1847 天前的主题,其中的信息可能已经有所发展或是发生改变。
当前用的 chrome 版本是 77,在调试时发现获取 window.DeviceOrientationEvent 是 undefined,排除了半天才发现是 http 的锅,只有 https 的网站才能拿到 DeviceOrientationEvent。那开发时弄个 https 也挺麻烦,有啥别的方法绕过吗?
2 条回复 • 2019-10-03 04:52:13 +08:00
|
|
1
Pastsong 2019-10-02 06:55:06 +08:00
localhost 可以绕过
|
|
|
2
codehz 2019-10-03 04:52:13 +08:00 2
chrome://flags/#unsafely-treat-insecure-origin-as-secure 填上你需要的域名,然后重启)
|