window.navigator All In One
window.navigator All In One
navigator
"use strict";
/**
*
* @author xgqfrms
* @license MIT
* @copyright xgqfrms
* @created 2020-11-11
* @modified
*
* @description
* @difficulty Easy Medium Hard
* @complexity O(n)
* @augments
* @example
* @link
* @solutions
*
* @best_solutions
*
*/
const log = console.log;
if(window.navigator) {
log(`window.navigator =`, navigator)
}
for(const item in navigator) {
// log(`navigator.${item} =`, item);
// log(`navigator.${item} =`, item, typeof item);
log(`navigator.${item} =`, item, navigator[item]);
}
// navigator.vendorSub = vendorSub
// navigator.productSub = productSub
// navigator.vendor = vendor
// navigator.maxTouchPoints = maxTouchPoints
// navigator.userActivation = userActivation
// navigator.doNotTrack = doNotTrack
// navigator.geolocation = geolocation
// navigator.connection = connection
// navigator.plugins = plugins
// navigator.mimeTypes = mimeTypes
// navigator.webkitTemporaryStorage = webkitTemporaryStorage
// navigator.webkitPersistentStorage = webkitPersistentStorage
// navigator.hardwareConcurrency = hardwareConcurrency
// navigator.cookieEnabled = cookieEnabled
// navigator.appCodeName = appCodeName
// navigator.appName = appName
// navigator.appVersion = appVersion
// navigator.platform = platform
// navigator.product = product
// navigator.userAgent = userAgent
// navigator.language = language
// navigator.languages = languages
// navigator.onLine = onLine
// navigator.getBattery = getBattery
// navigator.getGamepads = getGamepads
// navigator.javaEnabled = javaEnabled
// navigator.sendBeacon = sendBeacon
// navigator.vibrate = vibrate
// navigator.scheduling = scheduling
// navigator.xr = xr
// navigator.mediaCapabilities = mediaCapabilities
// navigator.permissions = permissions
// navigator.locks = locks
// navigator.wakeLock = wakeLock
// navigator.usb = usb
// navigator.mediaSession = mediaSession
// navigator.clipboard = clipboard
// navigator.credentials = credentials
// navigator.keyboard = keyboard
// navigator.mediaDevices = mediaDevices
// navigator.storage = storage
// navigator.serviceWorker = serviceWorker
// navigator.deviceMemory = deviceMemory
// navigator.presentation = presentation
// navigator.bluetooth = bluetooth
// navigator.registerProtocolHandler = registerProtocolHandler
// navigator.unregisterProtocolHandler = unregisterProtocolHandler
// navigator.getInstalledRelatedApps = getInstalledRelatedApps
// navigator.clearAppBadge = clearAppBadge
// navigator.setAppBadge = setAppBadge
// navigator.getUserMedia = getUserMedia
// navigator.requestMIDIAccess = requestMIDIAccess
// navigator.requestMediaKeySystemAccess = requestMediaKeySystemAccess
// navigator.webkitGetUserMedia = webkitGetUserMedia
导航器界面表示用户代理的状态和身份。它允许脚本查询并注册自己以进行一些活动。
https://developer.mozilla.org/en-US/docs/Web/API/Navigator
多点触控检测
navigator.maxTouchPoints
const log = console.log;
const touchPoints = navigator.maxTouchPoints;
if (touchPoints > 1) {
log(` your browser supports multi-touch`)
} else {
log(` your browser not supports multi-touch`)
}
https://www.w3.org/TR/pointerevents2/#extensions-to-the-navigator-interface
https://developer.mozilla.org/en-US/docs/Web/API/Navigator/maxTouchPoints
refs
UA
https://developer.mozilla.org/en-US/docs/Web/HTTP/Browser_detection_using_the_user_agent
xgqfrms 2012-2020
www.cnblogs.com 发布文章使用:只允许注册用户才可以访问!
window.navigator All In One的更多相关文章
- 完美解决window.navigator.geolocation.getCurrentPosition,在IOS10系统中无法定位问题
目前由于许多用户都将电话升级到了iOS系统,苹果的iOS 10已经正式对外推送,相信很多用户已经更新到了最新的系统.然而,如果web站没有及时支持https协议的话,当很多用户在iOS 10下访问很多 ...
- javascript宿主对象之window.navigator
window.navigator用来反映浏览器及其功能信息的对象. // 检测浏览器版本信息 function getBrowserInfo(){ var Sys = {}; var ua = win ...
- 使用window.navigator.userAgent属性判断浏览器类型及版本
使用window.navigator.userAgent属性判断浏览器类型及版本 2011-12-11 22:03:11 window.navigator.userAgent属性包含了浏览器类型.版本 ...
- Window.navigator
定义和用法 userAgent 属性是一个只读的字符串,声明了浏览器用于 HTTP 请求的用户代理头的值. 一般来讲,它是在 navigator.appCodeName 的值之后加上斜线和 navig ...
- 解决window.navigator.geolocation.getCurrentPosition在IOS10系统中无法进行地理定位问题
昨天接到用户通知说在点击"看场地"时无法获取地理位置信息. 在接到通知时,首先想到的是排查机型问题.由于客户多为IOS用户,所以最先看的是在安卓是有没有此问题的发生,调查结果为安卓 ...
- JavaScript Window Navigator
window.navigator 对象包含有关访问者浏览器的信息. Window Navigator window.navigator 对象在编写时可不使用 window 这个前缀. 实例 <d ...
- JavaScript Window Navigator 浏览器本身的信息
window.navigator 对象包含有关访问者浏览器的信息. Window Navigator window.navigator 对象在编写时可不使用 window 这个前缀. Navigato ...
- Window Navigator对象
Window Navigator对象 txt = "<p>浏览器代号: " + navigator.appCodeName + "</p>&quo ...
- window.navigator.userAgent $_SERVER['HTTP_USER_AGENT']
wjs php返回结果一致 <script> !function () { var UA = window.navigator.userAgent, docEl = document.do ...
- window.navigator.standalone 检测iOS WebApp是否运行在全屏模式
iOS上的Safari浏览器可以让Web应用程序全屏显示,以取得类似本地应用的显示效果.但是这需要用户把Web应用程序的图标添加到主屏幕才可以.作为开发者,为了更好的显示效果,我们可能希望自己开发的W ...
随机推荐
- smtplib.py
def _print_debug(self, *args): if self.debuglevel > 1: print(datetime.datetime.now().time(), *arg ...
- javamail发送邮件,支持yahoo,google,163.com,qq.com邮件发送
https://www.iteye.com/blog/fangyunfeng-1847352 https://blog.csdn.net/weixin_38465623/article/details ...
- Pulsar Pub/Sub Messaging
The Apache Software Foundation Announces Apache Pulsar as a Top-Level Project : The Apache Software ...
- 一本通提高篇——斜率优化DP
斜率优化DP:DP的一种优化形式,主要用于优化如下形式的DP f[i]=f[j]+x[i]*x[j]+... 学习可以参考下面的博客: https://www.cnblogs.com/Xing-Lin ...
- requestAnimationFrame小结
背景 在Web应用中,实现动画效果的方法比较多,Javascript 中可以通过定时器 setTimeout或者setInterval 来实现,css3 可以使用 transition 和 anima ...
- 31.FTP简介
1.FTP 是一种在互联网中进行文件传输的协议,基于客户端/服务器模式,默认使用20.21号端口,其中端口20(数据端口)用于进行数据传输,端口21(命令端口)用于接受客户端发出的相关FTP 命令与参 ...
- Pytest(5)美化插件进度条pytest-sugar
前言 在我们进行自动化测试的时候,用例往往是成百上千,执行的时间是几十分钟或者是小时级别.有时,我们在调试那么多用例的时候,不知道执行到什么程度了,而pytest-sugar插件能很好解决我们的痛点. ...
- Ubuntu18.04系统设置为中文语言
1.选择右上角设置按钮 2.管理已安装的语言 3.安装简体中文 安装好后是这样的 会发现汉语中文那一块是灰色的,怎么点都点不亮 4.拖拽 汉语(中国) 到最顶边 然后应用 5.重启 然后就出现这个画面 ...
- <<Hive编程指南>>读书笔记
1. 设置hive以本地模式运行(即使当前用户是在分布式模式或伪分布式模式下执行也使用这种模式) set hive.exec.model.local.auto=true; 若想默认使用这个配置,可以将 ...
- Left join查询为空
这两个查询,上面查询返回空,下面能正常返回记录 两个表结构: left join 没有匹配上得到的b.dates,b.game_id和b.uid都是null值,在按b.dates=20200317 a ...