vue-moo
Version:
moo
456 lines (193 loc) • 12 kB
HTML
<html lang="" >
<head>
<meta charset="UTF-8">
<meta content="text/html; charset=utf-8" http-equiv="Content-Type">
<title>Device · GitBook</title>
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
<meta name="description" content="">
<meta name="generator" content="GitBook 3.2.3">
<link rel="stylesheet" href="../../gitbook/style.css">
<link rel="stylesheet" href="../../gitbook/gitbook-plugin-prism/prism.css">
<link rel="stylesheet" href="../../gitbook/gitbook-plugin-search/search.css">
<link rel="stylesheet" href="../../gitbook/gitbook-plugin-fontsettings/website.css">
<link rel="stylesheet" href="../../gitbook/gitbook-plugin-theme-vuejs-2/vue.css">
<meta name="HandheldFriendly" content="true"/>
<meta name="viewport" content="width=device-width, initial-scale=1, user-scalable=no">
<meta name="apple-mobile-web-app-capable" content="yes">
<meta name="apple-mobile-web-app-status-bar-style" content="black">
<link rel="apple-touch-icon-precomposed" sizes="152x152" href="../../gitbook/images/apple-touch-icon-precomposed-152.png">
<link rel="shortcut icon" href="../../gitbook/images/favicon.ico" type="image/x-icon">
<link rel="next" href="Date.html" />
<link rel="prev" href="Assert.html" />
</head>
<body>
<div class="book">
<div class="book-summary">
<div id="book-search-input" role="search">
<input type="text" placeholder="Type to search" />
</div>
<nav role="navigation">
<ul class="summary">
<li class="chapter " data-level="1.1" data-path="../../">
<a href="../../">
Introduction
</a>
</li>
<li class="chapter " data-level="1.2" data-path="../component/HOME.html">
<a href="../component/HOME.html">
组件(component)
</a>
</li>
<li class="chapter " data-level="1.3" data-path="HOME.html">
<a href="HOME.html">
工具箱(util)
</a>
<ul class="articles">
<li class="chapter " data-level="1.3.1" data-path="Array.html">
<a href="Array.html">
Array
</a>
</li>
<li class="chapter " data-level="1.3.2" data-path="Assert.html">
<a href="Assert.html">
Assert
</a>
</li>
<li class="chapter active" data-level="1.3.3" data-path="Device.html">
<a href="Device.html">
Device
</a>
</li>
<li class="chapter " data-level="1.3.4" data-path="Date.html">
<a href="Date.html">
Date
</a>
</li>
<li class="chapter " data-level="1.3.5" data-path="Dom.html">
<a href="Dom.html">
Dom
</a>
</li>
<li class="chapter " data-level="1.3.6" data-path="Http.html">
<a href="Http.html">
Http
</a>
</li>
<li class="chapter " data-level="1.3.7" data-path="String.html">
<a href="String.html">
String
</a>
</li>
<li class="chapter " data-level="1.3.8" data-path="Storage.html">
<a href="Storage.html">
Storage
</a>
</li>
</ul>
</li>
<li class="chapter " data-level="1.4" data-path="../drive/HOME.html">
<a href="../drive/HOME.html">
驱动器(drive)
</a>
<ul class="articles">
<li class="chapter " data-level="1.4.1" data-path="../drive/Http.html">
<a href="../drive/Http.html">
Http
</a>
</li>
<li class="chapter " data-level="1.4.2" data-path="../drive/Vue.html">
<a href="../drive/Vue.html">
Vue
</a>
</li>
</ul>
</li>
<li class="chapter " data-level="1.5" data-path="../planes/HOME.html">
<a href="../planes/HOME.html">
Planes
</a>
</li>
<li class="divider"></li>
<li>
<a href="https://www.gitbook.com" target="blank" class="gitbook-link">
Published with GitBook
</a>
</li>
</ul>
</nav>
</div>
<div class="book-body">
<div class="body-inner">
<div class="book-header" role="navigation">
<!-- Title -->
<h1>
<i class="fa fa-circle-o-notch fa-spin"></i>
<a href="../.." >Device</a>
</h1>
</div>
<div class="page-wrapper" tabindex="-1" role="main">
<div class="page-inner">
<div id="book-search-results">
<div class="search-noresults">
<section class="normal markdown-section">
<h1 id="device">Device</h1>
<h2 id="utildevicetype">util.Device.type</h2>
<p>设备符合相关类型才会执行。</p>
<pre class="language-"><code>util.Device.type.windows(() => {
console.log('do it');
});
util.Device.type.mac(() => {
console.log('do it');
});
util.Device.type.android(() => {
console.log('do it');
});
util.Device.type.ios(() => {
console.log('do it');
});
// 回调函数返回的结果即是该方法的返回值,未执行时返回undefined。
util.Device.type.browser(() => {
console.log('do it');
return true;
});
</code></pre>
</section>
</div>
<div class="search-results">
<div class="has-results">
<h1 class="search-results-title"><span class='search-results-count'></span> results matching "<span class='search-query'></span>"</h1>
<ul class="search-results-list"></ul>
</div>
<div class="no-results">
<h1 class="search-results-title">No results matching "<span class='search-query'></span>"</h1>
</div>
</div>
</div>
</div>
</div>
</div>
<a href="Assert.html" class="navigation navigation-prev " aria-label="Previous page: Assert">
<i class="fa fa-angle-left"></i>
</a>
<a href="Date.html" class="navigation navigation-next " aria-label="Next page: Date">
<i class="fa fa-angle-right"></i>
</a>
</div>
<script>
var gitbook = gitbook || [];
gitbook.push(function() {
gitbook.page.hasChanged({"page":{"title":"Device","level":"1.3.3","depth":2,"next":{"title":"Date","level":"1.3.4","depth":2,"path":"documents/util/Date.md","ref":"documents/util/Date.md","articles":[]},"previous":{"title":"Assert","level":"1.3.2","depth":2,"path":"documents/util/Assert.md","ref":"documents/util/Assert.md","articles":[]},"dir":"ltr"},"config":{"plugins":["prism","-highlight","prism-themes","theme-vuejs-2"],"styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"pluginsConfig":{"prism":{},"prism-themes":{},"search":{},"lunr":{"maxIndexSize":1000000,"ignoreSpecialCharacters":false},"sharing":{"facebook":true,"twitter":true,"google":false,"weibo":false,"instapaper":false,"vk":false,"all":["facebook","google","twitter","weibo","instapaper"]},"fontsettings":{"theme":"white","family":"sans","size":2},"theme-vuejs-2":{},"theme-default":{"styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"showLevel":false}},"config":{"prism":{"css":["prismjs/themes/prism-coy.css"],"lang":{"flow":"typescript"}}},"theme":"default","pdf":{"pageNumbers":true,"fontSize":12,"fontFamily":"Arial","paperSize":"a4","chapterMark":"pagebreak","pageBreaksBefore":"/","margin":{"right":62,"left":62,"top":56,"bottom":56}},"structure":{"langs":"LANGS.md","readme":"README.md","glossary":"GLOSSARY.md","summary":"SUMMARY.md"},"variables":{},"gitbook":"*"},"file":{"path":"documents/util/Device.md","mtime":"2018-02-12T08:36:04.814Z","type":"markdown"},"gitbook":{"version":"3.2.3","time":"2018-02-23T06:59:45.706Z"},"basePath":"../..","book":{"language":""}});
});
</script>
</div>
<script src="../../gitbook/gitbook.js"></script>
<script src="../../gitbook/theme.js"></script>
<script src="../../gitbook/gitbook-plugin-search/search-engine.js"></script>
<script src="../../gitbook/gitbook-plugin-search/search.js"></script>
<script src="../../gitbook/gitbook-plugin-lunr/lunr.min.js"></script>
<script src="../../gitbook/gitbook-plugin-lunr/search-lunr.js"></script>
<script src="../../gitbook/gitbook-plugin-sharing/buttons.js"></script>
<script src="../../gitbook/gitbook-plugin-fontsettings/fontsettings.js"></script>
</body>
</html>