HTML5振动API支持(HTML5 vibration API support)
我检查了http://caniuse.com/,但找不到有关振动API兼容性的任何信息。
哪些浏览器支持它?
I checked on http://caniuse.com/ but can't find anything about compatibility for the vibration API.
Which browsers support it?
原文:https://stackoverflow.com/questions/14498338
更新时间:2019-11-03 21:08
最满意答案
更新[2014-03-07] :Firefox,Chrome和Opera现在支持Vibration API。 我还在caniuse.com上提供了这些信息。
振动API仍然主要不受支持。 Firefox 16+是目前唯一支持API的浏览器。
Update [2014-03-07]: The Vibration API is now supported by Firefox, Chrome, and Opera. I've also made this information available on on caniuse.com.
The Vibration API is still primarily unsupported. Firefox 16+ is currently the only browser with support for the API.
相关问答
这可能有助于: http : //caniuse.com/#search=history This might help : http://caniuse.com/#search=history
if (window.history && window.history.pushState)
另请参阅这个全合一的几乎按字母顺序排列的无瑕疵检测指南 if (window.history && window.history.pushState)
See also this All-In-One Almost-Alphabetical No-Bullshit Guide to Detecting Everything
检查全局历史记录对象上是否存在pushState()方法应该足够了。 function supports_history_api() {
return !!(window.history && history.pushState);
}
对于更一般的HTML 5功能检测,我会看Modernizer http://diveintohtml5.info/detect.html#modernizr 这将使您的代码免受每个测试的混乱细节的影响,使代码更具可读性并且更少出错。 使用您网页上的Moder
...
我过去一直在玩这个游戏: http : //aquantum-demo.appspot.com/file-upload 对我在做的事情看起来很合理。 I've played with this in the past: http://aquantum-demo.appspot.com/file-upload Seemed reasonable for what I was doing.
更新[2014-03-07] :Firefox,Chrome和Opera现在支持Vibration API。 我还在caniuse.com上提供了这些信息。 基于这篇文章 : 振动API仍然主要不受支持。 Firefox 16+是目前唯一支持API的浏览器。 Update [2014-03-07]: The Vibration API is now supported by Firefox, Chrome, and Opera. I've also made this information av
...
没一会儿。 我在1-2个月前问了Chrome团队和Firefox团队,他们都没有具体的时间表。 它似乎还不是优先事项。 在10月28日我和FF人的电子邮件中,他们回答说: 我假设你指的是路径/模式对象和相关的变化; 有 - AFAIK - 没有立即计划实施它们。 最近进入2D画布实施的大部分工作都是重构; 特别是,我们过去有两个独立的实现,其中一个已在几个星期前被删除。 Not for a while. I asked both the Chrome team and the Firefox te
...
var visibilityHidden, visibilityChange;
if (typeof document.hidden !== "undefined") { // Opera 12.10 and Firefox 18 and later support
visibilityHidden = "hidden";
visibilityChange = "visibilitychange";
} else if (typeof docume
...
有多个部分需要检查以下支持: //Full File API support.
if ( window.FileReader && window.File && window.FileList && window.Blob )
{
//Supported
}
else alert( "Not supported" );
你的第二个要求: 我也想知道如何在不使用HTML5 fileAPI的情况下阅读文件内容...但不使用ActiveXObject。 你可以做的是这样的: 有一个ifram
...
您可以简单地使用jQuery使用的原始Sizzle引擎(由jQuery的作者John Resig编写)。 这是Sizzle自己的描述: 一个纯粹的JavaScript CSS选择器引擎,可以轻松插入主机库。 如果你想确保你不使用Sizzle如果querySelectorAll本地支持(即使Sizzle总是在可用时使用querySelectorAll ),使用这个: if ( ! document.querySelectorAll ) document.querySelectorAll = Sizz
...
浏览器支持 算了 甚至IE 9也不支持history.pushState 。 移动浏览器也不是很安全。 但是有一个库(见下文)使这种不兼容性对开发人员完全透明。 图书馆 好吧,在纯HTML 5环境中,历史api非常简单。 对于其他人来说, history.js库已经得到了相当多的关注,而且它提供了对旧哈希写入的自动回退 在小型网站上 那么,你最好把你的JavaScript和潜在的国家组织起来。 但如果是这样,我认为没问题。 历史和jQuery和插件 我现在已经在两个项目中使用了这两个项目。 我还没
...