zhichiyixiazhegewangzhan

By at • 1141次点击
galaxyi9500

shougongzhichi


zhichiyixiazhegewangzhan


帽哦,2334

galaxyi9500 at 2016-10-07 22:46
1

``` 代码支持

onLaunch: <span class="hljs-function"><span class="hljs-keyword">function</span> <span class="hljs-params">()</span> {</span>

&lt;span class=&quot;hljs-comment&quot;&gt;//调用API从本地缓存中获取数据&lt;/span&gt;
&lt;span class=&quot;hljs-keyword&quot;&gt;var&lt;/span&gt; logs = wx.getStorageSync(&lt;span class=&quot;hljs-string&quot;&gt;'logs'&lt;/span&gt;) || []
logs.unshift(&lt;span class=&quot;hljs-built_in&quot;&gt;Date&lt;/span&gt;.now())
wx.setStorageSync(&lt;span class=&quot;hljs-string&quot;&gt;'logs'&lt;/span&gt;, logs)

},```

琴歌 at 2016-10-08 18:40
2
登录 后发表评论