1 Star 0 Fork 0

Kaelinda/kaelindaTop

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
该仓库未声明开源许可证文件(LICENSE),使用请关注具体项目描述及其代码上游依赖。
克隆/下载
all_1.html 33.87 KB
一键复制 编辑 原始数据 按行查看 历史
zuosong 提交于 2019-03-12 15:13 . 2019-03-12 15:13:57
12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145
<!doctype html>
<html class="no-js" lang="en">
<head>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>
kaelinda
</title>
<link href="atom.xml" rel="alternate" title="kaelinda" type="application/atom+xml">
<link rel="stylesheet" href="asset/css/foundation.min.css" />
<link rel="stylesheet" href="asset/css/docs.css" />
<script src="asset/js/vendor/modernizr.js"></script>
<script src="asset/js/vendor/jquery.js"></script>
<script src="asset/highlightjs/highlight.pack.js"></script>
<link href="asset/highlightjs/styles/github.css" media="screen, projection" rel="stylesheet" type="text/css">
<script>hljs.initHighlightingOnLoad();</script>
<script type="text/javascript">
function before_search(){
var searchVal = 'site:kaelinda.top ' + document.getElementById('search_input').value;
document.getElementById('search_q').value = searchVal;
return true;
}
</script>
</head>
<body class="antialiased hide-extras">
<div class="marketing off-canvas-wrap" data-offcanvas>
<div class="inner-wrap">
<nav class="top-bar docs-bar hide-for-small" data-topbar>
<section class="top-bar-section">
<div class="row">
<div style="position: relative;width:100%;"><div style="position: absolute; width:100%;">
<ul id="main-menu" class="left">
<li id=""><a target="_self" href="index.html">最近更新</a></li>
<li id=""><a target="_self" href="archives.html">归档目录</a></li>
<li id="ios.css"><a target="_self" href="ios.html">iOS</a></li>
<li id="swift.css"><a target="_self" href="swift.html">Swift</a></li>
<li id="reactnative.css"><a target="_self" href="reactnative.html">RN</a></li>
<li id="js.css"><a target="_self" href="js.html">JS</a></li>
<li id="shell.css"><a target="_self" href="shell.html">shell</a></li>
<li id="coding.css"><a target="_self" href="coding.html">编程</a></li>
<li id="live.css"><a target="_self" href="live.html">随笔</a></li>
<li id="app.css"><a target="_blank" href="app.html">APP推荐</a></li>
</ul>
<ul class="right" id="search-wrap">
<li>
<form target="_blank" onsubmit="return before_search();" action="http://google.com/search" method="get">
<input type="hidden" id="search_q" name="q" value="" />
<input tabindex="1" type="search" id="search_input" placeholder="Search"/>
</form>
</li>
</ul>
</div></div>
</div>
</section>
</nav>
<nav class="tab-bar show-for-small">
<a href="javascript:void(0)" class="left-off-canvas-toggle menu-icon">
<span> &nbsp; kaelinda</span>
</a>
</nav>
<aside class="left-off-canvas-menu">
<ul class="off-canvas-list">
<li><a target="_self" href="index.html">最近更新</a></li>
<li><a target="_self" href="archives.html">归档目录</a></li>
<li><a target="_self" href="ios.html">iOS</a></li>
<li><a target="_self" href="swift.html">Swift</a></li>
<li><a target="_self" href="reactnative.html">RN</a></li>
<li><a target="_self" href="js.html">JS</a></li>
<li><a target="_self" href="shell.html">shell</a></li>
<li><a target="_self" href="coding.html">编程</a></li>
<li><a target="_self" href="live.html">随笔</a></li>
<li><a target="_blank" href="app.html">APP推荐</a></li>
<li><label>Categories</label></li>
<li><a href="reactnative.html">React-Native</a></li>
<li><a href="ios.html">iOS</a></li>
<li><a href="app.html">MacAPP</a></li>
<li><a href="swift.html">Swift</a></li>
<li><a href="js.html">JavaScript</a></li>
<li><a href="vue.html">Vue</a></li>
<li><a href="shell.html">shell</a></li>
<li><a href="%E7%BD%91%E7%BB%9C.html">网络</a></li>
</ul>
</aside>
<a class="exit-off-canvas" href="#"></a>
<section id="main-content" role="main" class="scroll-container">
<script type="text/javascript">
$(function(){
$('#menu_item_index').addClass('is_active');
});
</script>
<div class="row">
<div class="large-8 medium-8 columns">
<div class="markdown-body home-categories">
<div class="article">
<a class="clearlink" href="15226603064743.html">
<h1>每天学习一个shell技能(6)</h1>
<div class="a-content">
<div class="a-content-text">
<h2 id="toc_0">test</h2>
<h3 id="toc_1">test文件</h3>
<pre><code class="language-text">if test -e ./test.sh
then
echo &#39;文件已存在!&#39;
else
echo &#39;文件不存在!&#39;
fi
</code></pre>
<ul>
<li>-e fileName : 如果文件存在则为真</li>
<li>-r fileName : 如果文件存在且可读则为真</li>
<li>-w fileName : 如果文件存在且可写则为真</li>
<li>-x fileName : 如果文件存在且可执行则为真</li>
<li>-s fileName: 文件存在且至少有一个字符</li>
<li>-d fileName : 文件存在且为目录</li>
<li>-f fileName: 文件存在且为文件</li>
<li>-c fileName:文件存在,且为字符型特殊文件</li>
<li>-b fileName: 如果文件存在且为块特殊文件则为真</li>
</ul>
</div>
</div>
</a>
<div class="read-more clearfix">
<div class="more-left left">
<a href="15226603064743.html">Read more</a>&nbsp;&nbsp;
<span class="date">2018/4/2</span>
<span>posted in&nbsp;</span>
<span class="posted-in"><a href='shell.html'>shell</a></span>
</div>
<div class="more-right right">
<span class="comments">
</span>
</div>
</div>
</div><!-- article -->
<div class="article">
<a class="clearlink" href="15224936933861.html">
<h1>每天学习一个shell技能(5)</h1>
<div class="a-content">
<div class="a-content-text">
<h2 id="toc_0">Shell echo命令</h2>
<h3 id="toc_1">打印字符</h3>
<pre><code class="language-text">// 下面两行代码效果一致
echo &quot;It is a test&quot;
echo It is a test
</code></pre>
<h3 id="toc_2">打印转义字符</h3>
<pre><code class="language-text">echo &quot;\&quot;It is a test\&quot;&quot;
// 引号也可以省略
echo \&quot;It is a test\&quot;
</code></pre>
<p>打印结果:</p>
<pre><code class="language-text">&quot;It is a test&quot;
&quot;It is a test&quot;
</code></pre>
</div>
</div>
</a>
<div class="read-more clearfix">
<div class="more-left left">
<a href="15224936933861.html">Read more</a>&nbsp;&nbsp;
<span class="date">2018/3/31</span>
<span>posted in&nbsp;</span>
<span class="posted-in"><a href='shell.html'>shell</a></span>
</div>
<div class="more-right right">
<span class="comments">
</span>
</div>
</div>
</div><!-- article -->
<div class="article">
<a class="clearlink" href="15224613481161.html">
<h1>每天学习一个shell技能(4)</h1>
<div class="a-content">
<div class="a-content-text">
<h2 id="toc_0">shell基本运算符</h2>
<p>基本使用:</p>
<pre><code class="language-text">#!/bin/bash
val=`expr 2 + 2`
echo &quot;两数之和为 : $val&quot;
</code></pre>
<ul>
<li>表达式和运算符之间要有空格,例如 2+2 是不对的,必须写成 2 + 2,这与我们熟悉的大多数编程语言不一样</li>
<li>完整的表达式要被 ` ` 包含,注意这个字符不是常用的单引号,在 Esc 键下边</li>
</ul>
</div>
</div>
</a>
<div class="read-more clearfix">
<div class="more-left left">
<a href="15224613481161.html">Read more</a>&nbsp;&nbsp;
<span class="date">2018/3/31</span>
<span>posted in&nbsp;</span>
<span class="posted-in"><a href='shell.html'>shell</a></span>
</div>
<div class="more-right right">
<span class="comments">
</span>
</div>
</div>
</div><!-- article -->
<div class="article">
<a class="clearlink" href="15223750607281.html">
<h1>每天学习一个shell技能 (3)</h1>
<div class="a-content">
<div class="a-content-text">
<h2 id="toc_0">shell参数传递</h2>
<p>我们可以在脚本执行时,向脚本传递参数</p>
<pre><code class="language-text">// 终端运行 脚本,并传入参数
sh testBash.sh 0 1 2
echo &quot;Shell 传递参数实例!&quot;
echo &quot;\$0 =&gt; $0&quot;
echo &quot;\$1 =&gt; $1&quot;
</code></pre>
<p>打印结果:</p>
<pre><code class="language-text">Shell 传递参数实例!
$0 =&gt; testBash.sh
$1 =&gt; 0
</code></pre>
</div>
</div>
</a>
<div class="read-more clearfix">
<div class="more-left left">
<a href="15223750607281.html">Read more</a>&nbsp;&nbsp;
<span class="date">2018/3/30</span>
<span>posted in&nbsp;</span>
<span class="posted-in"><a href='shell.html'>shell</a></span>
</div>
<div class="more-right right">
<span class="comments">
</span>
</div>
</div>
</div><!-- article -->
<div class="article">
<a class="clearlink" href="15223028228569.html">
<h1>每天学习一个shell技能 (1)</h1>
<div class="a-content">
<div class="a-content-text">
<h2 id="toc_0">准备</h2>
<p>bash 环境位置</p>
<pre><code class="language-text">#!/bin/bash
</code></pre>
<p><code>#!</code> 一个约定的标记,它告诉系统这个脚本需要什么解释器来执行,即使用哪一种 Shell</p>
</div>
</div>
</a>
<div class="read-more clearfix">
<div class="more-left left">
<a href="15223028228569.html">Read more</a>&nbsp;&nbsp;
<span class="date">2018/3/29</span>
<span>posted in&nbsp;</span>
<span class="posted-in"><a href='shell.html'>shell</a></span>
</div>
<div class="more-right right">
<span class="comments">
</span>
</div>
</div>
</div><!-- article -->
<div class="article">
<a class="clearlink" href="15223210751913.html">
<h1>每天学习一个shell 技能 (2)</h1>
<div class="a-content">
<div class="a-content-text">
<h2 id="toc_0">Shell 数组</h2>
<h3 id="toc_1">定义数组</h3>
<pre><code class="language-bash">array_name=(value1 value2 value3)
array_name2=(
value1
value2
value3
)
// 单独定义某个分量的值
array_name(0)=value0
</code></pre>
</div>
</div>
</a>
<div class="read-more clearfix">
<div class="more-left left">
<a href="15223210751913.html">Read more</a>&nbsp;&nbsp;
<span class="date">2018/3/29</span>
<span>posted in&nbsp;</span>
<span class="posted-in"><a href='shell.html'>shell</a></span>
</div>
<div class="more-right right">
<span class="comments">
</span>
</div>
</div>
</div><!-- article -->
<div class="article">
<a class="clearlink" href="15168925544178.html">
<h1>从零开始学习使用 vuex</h1>
<div class="a-content">
<div class="a-content-text">
<blockquote>
<p>本文是建立在,对vuex理论有一定理解的基础上写的。<br/>
因为官方文档的写法是 针对 有一定的vue开发经验 和 JavaScript 有一定理解的开发者看的,对于小白级别的我来说,理解起来有一定困难。所以,唯一想我一向的小白想尽快上手vuex....</p>
</blockquote>
<p><a href="https://vuex.vuejs.org/zh-cn/installation.html">详情请参考vuex官方文档</a></p>
<h2 id="toc_0">安装</h2>
<h3 id="toc_1">直接下载 CDN 安装</h3>
<p>CDN 链接地址:<code>https://unpkg.com/vuex</code><br/>
指定到固定版本:<code>https://unpkg.com/vuex@2.0.0</code></p>
<pre><code class="language-text">&lt;script src=&quot;/path/to/vue.js&quot;&gt;&lt;/script&gt;
&lt;script src=&quot;/path/to/vuex.js&quot;&gt;&lt;/script&gt;
</code></pre>
<h3 id="toc_2">npm 方式安装 (推荐!简单快捷,便于管理)</h3>
<p><code>npm install -save vuex</code></p>
<h3 id="toc_3">yar</h3>
<p><code>yarn add vuex</code></p>
<h3 id="toc_4">自己构建</h3>
<pre><code class="language-bash">git clone https://github.com/vuejs/vuex.git node_modules/vuex
cd node_modules/vuex
npm install
npm run build
</code></pre>
<h2 id="toc_5">导入vue工程中使用</h2>
<ul>
<li>main.js 入口文件</li>
</ul>
<blockquote>
<p>按照如下方式导入,工程就可以使用vuex的环境了</p>
</blockquote>
<pre><code class="language-javascript">// 导入vuex头文件
import Vuex from &#39;vuex&#39;
// 这里表示全局导入vuex
Vue.use(Vuex)
// 这里是我自定义的store文件 导出store对象
import store from &#39;@/study/vuexStudy/store/store.js&#39;
</code></pre>
<blockquote>
<p>入口组件<App/>中,绑定store</p>
</blockquote>
<pre><code class="language-text">new Vue({
el: &#39;#app&#39;,
template: &#39;&lt;App/&gt;&#39;,
components: { App },
store
})
</code></pre>
<p>到这里 算是万里长征走了第一步。</p>
<h3 id="toc_6">创建Store对象</h3>
<h4 id="toc_7">store 的结构:</h4>
<pre><code class="language-javascript">export const store = new Vuex.Store({
// ------state:状态值存储,这里可以存储n个状态的值
state: {count: &#39;1&#39;},
// ------getter:store中定义的getters可以认为是store的计算属性
// getters接收state作为其第一个参数
getters: {
done (state) {
return state.count + 5
}
},
// ------mutations:状态值的改变,操作状态值
// $store.commit(mutationsName, params)是更改状态值的唯一方法
mutations: {
increment (state) {
// 变更状态
state.count++
}
},
// ------actions:可以认为是包装了mutations的function 需要用 dispatch(actionName) 的方式去派发
actions: {
add (context) {
context.commit(&#39;increment&#39;)
},
addAsync (context) {
// 延时1秒
setTimeout(() =&gt; {
context.commit(&#39;increment&#39;)
}, 1000)
}
},
// store可以合并几个子store,以此来进行项目的模块化
modules: {
a: moduleA,
b: moduleB
}
})
</code></pre>
<h4 id="toc_8">编辑定义store实体对象:</h4>
<ul>
<li>store.js文件中</li>
</ul>
<blockquote>
<p>这里为了便于抽离 我们外部声明城对象实体后嵌入绑定到store</p>
</blockquote>
<ol>
<li><p>创建一个store对象</p>
<pre><code class="language-javascript">export default const store = new Vuex.Store({
state,//绑定之前创建的state对象到store中<br/>
mutations,<br/>
getters,<br/>
actions,<br/>
modules<br/>
})
</code></pre></li>
<li><p>定义一个状态对象 <code>state</code>(实体)</p>
<pre><code class="language-javascript">const state = {
count: 0,<br/>
state1: 1,<br/>
state2: 2,<br/>
state3: 3<br/>
}
</code></pre></li>
<li><p>定义getters对象</p>
<pre><code class="language-text">const getters = {
done (state) {<br/>
return state.count + 5<br/>
},<br/>
getState1: function (state) {<br/>
return state.state3<br/>
},<br/>
// ES6简写<br/>
getState2: state =&gt; state.state2<br/>
}
</code></pre></li>
<li><p>.vue 文件中直接获取state值</p>
<p>首先导入辅助函数:</p>
<pre><code class="language-text">import {
mapState, <br/>
mapGetters, <br/>
mapMutations, <br/>
mapActions <br/>
} from &#39;vuex&#39;
</code></pre>
<ul>
<li>第一种方式:绑定到组件属性中,直接获取 (一般不用这个,绑定到computed中是最合适的)<code>$store.state.count</code>并使用</li>
</ul>
<pre><code class="language-javascript">export default {
data() {<br/>
return {<br/>
testCount: this.$store.state.count<br/>
}<br/>
}<br/>
}
</code></pre>
<ul>
<li>第二种方式: 绑定到计算属性中(适合对store中的原始状态值进行一定处理的情况)</li>
</ul>
<pre><code class="language-javascript">export default {
data() {<br/>
return {<br/>
testCount: this.$store.state.count<br/>
}<br/>
},<br/>
computed:{<br/>
testComputedCount1: function () {<br/>
return this.$store.state.count + 22<br/>
}<br/>
}<br/>
}
</code></pre>
<ul>
<li>第三种方式:mapState辅助函数绑定状态state值到组件计算属性中</li>
</ul>
<pre><code class="language-javascript">export default {
data() {<br/>
return {<br/>
testCount: this.$store.state.count<br/>
}<br/>
},<br/>
computed:{<br/>
testComputedCount1: function () {<br/>
return this.$store.state.count + 22<br/>
},<br/>
...mapState({<br/>
count: state =&gt; state.count,<br/>
mapState1: state =&gt; state.state1,<br/>
mapState2: state =&gt; state.state2<br/>
}),<br/>
}<br/>
}
</code></pre>
<ul>
<li>第四种方式:使用store中绑定的getters进行获取</li>
</ul>
<pre><code class="language-javascript">export default {
data() {<br/>
return {<br/>
testCount: this.$store.state.count<br/>
}<br/>
},<br/>
computed:{<br/>
testComputedCount1: function () {<br/>
return this.$store.state.count + 22<br/>
},<br/>
...mapState({<br/>
count: state =&gt; state.count,<br/>
mapState1: state =&gt; state.state1,<br/>
mapState2: state =&gt; state.state2<br/>
}),<br/>
testComputedGettersCount2: funtion () {<br/>
return this.$store.getters.done<br/>
}<br/>
}<br/>
}
</code></pre>
<ul>
<li>第五种方式: 借助mapGetters辅助函数绑定getters到vue的计算属性中</li>
</ul>
<pre><code class="language-javascript">export default {
data() {<br/>
return {<br/>
testCount: this.$store.state.count<br/>
}<br/>
},<br/>
computed:{<br/>
testComputedCount1: function () {<br/>
return this.$store.state.count + 22<br/>
},<br/>
...mapState({<br/>
count: state =&gt; state.count,<br/>
mapState1: state =&gt; state.state1,<br/>
mapState2: state =&gt; state.state2<br/>
}),<br/>
testComputedGettersCount2: funtion () {<br/>
return this.$store.getters.done<br/>
},<br/>
//直接绑定方法数组的方式<br/>
...mapGetters([<br/>
&#39;getState1&#39;,<br/>
&#39;getState2&#39;,<br/>
&#39;getState3&#39;<br/>
]),<br/>
//重命名对象绑定方式<br/>
...mapGetters({<br/>
mapGetterState1: &#39;getState1&#39;,<br/>
mapGetterState3: &#39;getState3&#39;<br/>
}),<br/>
}<br/>
}
</code></pre></li>
<li><p>触发动作行为改变状态值</p>
<blockquote>
<p>方式一:$store.commit(&#39;mutationsName&#39;)</p>
<p>方式二:$store.dispatch(&#39;actionsName&#39;) </p>
</blockquote>
<p>store.js文件中:</p>
<ul>
<li>初始化 mutations 和 actions (相当于是methods)</li>
</ul>
<pre><code class="language-text">const mutations = {
increment (state) {<br/>
// 变更状态<br/>
state.count = state.count * 5<br/>
}<br/>
}
</code></pre>
<pre><code class="language-text">import {action4} from &#39;@/path/actions.js&#39;
const actions = {<br/>
// 同步方法<br/>
add: function (context) {<br/>
context.commit(&#39;increment&#39;)<br/>
},<br/>
// 延时操作 用于网络请求啊啥的<br/>
addAsync (context) {<br/>
// 延时1秒<br/>
setTimeout(() =&gt; {<br/>
context.commit(&#39;increment&#39;)<br/>
}, 1000)<br/>
},<br/>
// 简写方式<br/>
action2 (context) {<br/>
context.commit(&#39;increment&#39;)<br/>
},<br/>
// 抽离到单独文件中,在导进封装好的变量来直接使用即可(导进来的目的是为了接收第一个参数:state),不绑定到store,需要手动传入store对象<br/>
action4: action4,<br/>
}
</code></pre></li>
</ol>
<ul>
<li><p>绑定action 和 mutations 到 methods,然后 调用就行了</p>
<pre><code class="language-text">export default {
methods: {<br/>
// 数组形式直接载入<br/>
...mapActions([<br/>
&#39;add&#39;<br/>
]),<br/>
// 重命名形式 <br/>
...mapActions({<br/>
add: &#39;add&#39;,<br/>
addAsync: &#39;addAsync&#39;,<br/>
action4: &#39;action4&#39;<br/>
}),<br/>
// 同上<br/>
...mapMutations([<br/>
&#39;increment&#39;<br/>
]),<br/>
...mapMutations({<br/>
incrementMutation: &#39;increment&#39;<br/>
})<br/>
}<br/>
}
</code></pre></li>
</ul>
</div>
</div>
</a>
<div class="read-more clearfix">
<div class="more-left left">
<span class="date">2018/1/25</span>
<span>posted in&nbsp;</span>
<span class="posted-in"><a href='vue.html'>Vue</a></span>
</div>
<div class="more-right right">
<span class="comments">
</span>
</div>
</div>
</div><!-- article -->
<div class="article">
<a class="clearlink" href="15151216159291.html">
<h1></h1>
<div class="a-content">
<div class="a-content-text">
<h1 id="toc_0">react-native-splash-screen 给安卓项目添加启动图</h1>
<h2 id="toc_1">react-native-splash-screen 基本配置</h2>
<ul>
<li>安装插件:<code>npm install react-native-splash-screen --save</code></li>
<li>关联项目:<code>react-native link react-native-splash-screen</code> or <code>rnpm link react-native-splash-screen</code></li>
</ul>
<blockquote>
<p>link 之后,安卓项目中会自动添加头文件 以及部分代码,为保证项目顺利运行,还请确认下面代码是否已经完善。</p>
</blockquote>
<ul>
<li><p>确保 <code>android/settings.gradle</code>文件夹已经有下面代码</p>
<pre><code class="language-javascript">include &#39;:react-native-splash-screen&#39;
project(&#39;:react-native-splash-screen&#39;).projectDir = new File(rootProject.projectDir, &#39;../node_modules/react-native-splash-screen/android&#39;)
</code></pre></li>
<li><p>android/app/build.gradle 文件中 添加依赖 <code>react-native-splash-screen</code></p>
<pre><code class="language-text">...
dependencies {<br/>
...<br/>
compile project(&#39;:react-native-splash-screen&#39;)<br/>
}
</code></pre></li>
</ul>
</div>
</div>
</a>
<div class="read-more clearfix">
<div class="more-left left">
<a href="15151216159291.html">Read more</a>&nbsp;&nbsp;
<span class="date">2018/1/5</span>
<span>posted in&nbsp;</span>
<span class="posted-in"><a href='reactnative.html'>React-Native</a></span>
</div>
<div class="more-right right">
<span class="comments">
</span>
</div>
</div>
</div><!-- article -->
<div class="article">
<a class="clearlink" href="15139057022845.html">
<h1>Rect-Native 之 Promise 深入浅出从入门到精通</h1>
<div class="a-content">
<div class="a-content-text">
<h2 id="toc_0">概念理解</h2>
<p><img src="https://ws1.sinaimg.cn/large/006tNc79ly1fhp9dw6vxpj307406ewek.jpg" alt="icon" title="React icon"/></p>
<blockquote>
<p>所谓Promise,简单说就是一个容器,里面保存着某个未来才会结束的事件(通常是一个异步操作)的结果。从语法上说,Promise 是一个对象,从它可以获取异步操作的消息。</p>
</blockquote>
</div>
</div>
</a>
<div class="read-more clearfix">
<div class="more-left left">
<a href="15139057022845.html">Read more</a>&nbsp;&nbsp;
<span class="date">2017/12/22</span>
<span>posted in&nbsp;</span>
<span class="posted-in"><a href='reactnative.html'>React-Native</a></span>
</div>
<div class="more-right right">
<span class="comments">
</span>
</div>
</div>
</div><!-- article -->
<div class="article">
<a class="clearlink" href="15137645005542.html">
<h1>ES6 笔记(Array)</h1>
<div class="a-content">
<div class="a-content-text">
<h2 id="toc_0">array</h2>
<ol>
<li><p>Array.from<br/>
将类似数组的对象(array-like object)和可遍历(iterable)的对象 转换为数组。</p>
<ul>
<li>类数组:有 length属性的对象</li>
<li>可遍历:包含Set Map.</li>
</ul></li>
<li><p>Array.of<br/>
该方法用于将一组值,转换为数组。</p></li>
</ol>
</div>
</div>
</a>
<div class="read-more clearfix">
<div class="more-left left">
<a href="15137645005542.html">Read more</a>&nbsp;&nbsp;
<span class="date">2017/12/20</span>
<span>posted in&nbsp;</span>
<span class="posted-in"><a href='js.html'>JavaScript</a></span>
</div>
<div class="more-right right">
<span class="comments">
</span>
</div>
</div>
</div><!-- article -->
<div class="row">
<div class="large-6 columns">
<p class="text-left" style="padding-top:25px;">
<a href="all.html">&laquo; Prev Page</a>
</p>
</div>
<div class="large-6 columns">
<p class="text-right" style="padding-top:25px;">
<a href="all_2.html">&raquo; Next Page</a>
</p>
</div>
</div>
</div>
</div><!-- large 8 -->
<div class="large-4 medium-4 columns">
<div class="hide-for-small">
<div id="sidebar" class="sidebar">
<div id="site-info" class="site-info">
<div class="site-a-logo"><img src="https://ws1.sinaimg.cn/large/006tNc79ly1fmpk9088gsj30sg0sgn33.jpg" /></div>
<h1>kaelinda</h1>
<div class="site-des">倘若我心中的山水,你眼中能看到,我便一步一莲花祈祷</div>
<div class="social">
<a target="_blank" class="twitter" target="_blank" href="https://twitter.com/KaelLVLinda" title="Twitter">Twitter</a>
<a target="_blank" class="github" target="_blank" href="https://github.com/Kaelzzs" title="GitHub">GitHub</a>
<a target="_blank" class="email" href="mailto:zhouzuosong_kael@163.com" title="Email">Email</a>
<a target="_blank" class="rss" href="atom.xml" title="RSS">RSS</a>
</div>
</div>
<div id="site-categories" class="side-item ">
<div class="side-header">
<h2>Categories</h2>
</div>
<div class="side-content">
<p class="cat-list">
<a href="reactnative.html"><strong>React-Native</strong></a>
<a href="ios.html"><strong>iOS</strong></a>
<a href="app.html"><strong>MacAPP</strong></a>
<a href="swift.html"><strong>Swift</strong></a>
<a href="js.html"><strong>JavaScript</strong></a>
<a href="vue.html"><strong>Vue</strong></a>
<a href="shell.html"><strong>shell</strong></a>
<a href="%E7%BD%91%E7%BB%9C.html"><strong>网络</strong></a>
</p>
</div>
</div>
<div id="site-categories" class="side-item">
<div class="side-header">
<h2>Recent Posts</h2>
</div>
<div class="side-content">
<ul class="posts-list">
<li class="post">
<a href="15523077857608.html">OC中枚举写法 以及 字符串枚举探索</a>
</li>
<li class="post">
<a href="15522686353535.html">iOS 动画全解 (1)</a>
</li>
<li class="post">
<a href="15501356584731.html">UITableView顶部空白的几种解决办法</a>
</li>
<li class="post">
<a href="15488351784332.html">Objective-C中的字符串类型枚举 探索</a>
</li>
<li class="post">
<a href="15409691048860.html">【Swift笔记】引用计数</a>
</li>
</ul>
</div>
</div>
</div><!-- sidebar -->
</div><!-- hide for small -->
</div><!-- large 4 -->
</div><!-- row -->
<div class="page-bottom clearfix">
<div class="row">
<p class="copyright">Copyright &copy; 2015
Powered by <a target="_blank" href="http://www.mweb.im">MWeb</a>,&nbsp;
Theme used <a target="_blank" href="http://github.com">GitHub CSS</a>.</p>
</div>
</div>
</section>
</div>
</div>
<script src="asset/js/foundation.min.js"></script>
<script>
$(document).foundation();
function fixSidebarHeight(){
var w1 = $('.markdown-body').height();
var w2 = $('#sidebar').height();
if (w1 > w2) { $('#sidebar').height(w1); };
}
$(function(){
fixSidebarHeight();
})
$(window).load(function(){
fixSidebarHeight();
});
</script>
<script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.1/MathJax.js?config=TeX-AMS-MML_HTMLorMML"></script><script type="text/x-mathjax-config">MathJax.Hub.Config({TeX: { equationNumbers: { autoNumber: "AMS" } }});</script>
</body>
</html>
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/kaelinda/kaelindaTop.git
git@gitee.com:kaelinda/kaelindaTop.git
kaelinda
kaelindaTop
kaelindaTop
master

搜索帮助

0d507c66 1850385 C8b1a773 1850385