{"id":33957,"date":"2024-11-25T17:10:48","date_gmt":"2024-11-25T09:10:48","guid":{"rendered":"https:\/\/fwq.ai\/blog\/33957\/"},"modified":"2024-11-25T17:10:48","modified_gmt":"2024-11-25T09:10:48","slug":"%e5%be%ae%e4%bf%a1%e5%b0%8f%e7%a8%8b%e5%ba%8f%e5%bc%80%e5%8f%91%ef%bc%88%e4%b8%80%ef%bc%89%e4%bb%8b%e7%bb%8d%e5%be%ae%e4%bf%a1%e5%bc%80%e5%8f%91%e8%80%85%e5%b7%a5%e5%85%b7%e4%bb%a5%e5%8f%8a%e5%b0%8f","status":"publish","type":"post","link":"https:\/\/fwq.ai\/blog\/33957\/","title":{"rendered":"\u5fae\u4fe1\u5c0f\u7a0b\u5e8f\u5f00\u53d1\uff08\u4e00\uff09\u4ecb\u7ecd\u5fae\u4fe1\u5f00\u53d1\u8005\u5de5\u5177\u4ee5\u53ca\u5c0f\u7a0b\u5e8f\u6846\u67b6"},"content":{"rendered":"<h4><span style=\"font-size:16px\"><img decoding=\"async\" src=\"https:\/\/img.php.cn\/upload\/article\/000\/000\/052\/606d0ddaa1419640.jpg\" class=\"aligncenter\" title=\"\u5fae\u4fe1\u5c0f\u7a0b\u5e8f\u5f00\u53d1\uff08\u4e00\uff09\u4ecb\u7ecd\u5fae\u4fe1\u5f00\u53d1\u8005\u5de5\u5177\u4ee5\u53ca\u5c0f\u7a0b\u5e8f\u6846\u67b6\u63d2\u56fe\" alt=\"\u5fae\u4fe1\u5c0f\u7a0b\u5e8f\u5f00\u53d1\uff08\u4e00\uff09\u4ecb\u7ecd\u5fae\u4fe1\u5f00\u53d1\u8005\u5de5\u5177\u4ee5\u53ca\u5c0f\u7a0b\u5e8f\u6846\u67b6\u63d2\u56fe\" \/><\/span><\/h4>\n<h4><span style=\"font-size:16px\">\u524d\u8a00<\/span><\/h4>\n<h3><span style=\"font-weight:normal\"><span style=\"font-size:16px\">\u4e00\u76f4\u4e0d\u6e29\u4e0d\u706b\u7684\u5fae\u4fe1\u5c0f\u7a0b\u5e8f2018\u5e74\u8fce\u6765\u4e86\u7b2c\u4e8c\u6625\uff0c\u5728\u6211\u7684\u8bb0\u5fc6\u4e2d\u968f\u7740<\/span><span style=\"font-family:Consolas, Inconsolata, Courier, monospace;font-size:16px;color:#c7254e\"><span>\u8df3\u4e00\u8df3<\/span><\/span><span style=\"font-size:16px\">\u5c0f\u6e38\u620f\u7684\u51fa\u73b0\uff0c\u4e00\u65f6\u95f4\u6570\u5343\u4e07\u7684\u5fae\u4fe1\u5c0f\u7a0b\u5e8f\u5982\u96e8\u540e\u6625\u7b0b\u822c\u51fa\u73b0\u5728\u6211\u4eec\u7684\u89c6\u7ebf\u91cc\u3002\u8ffd\u7740\u8fd9\u6ce2\u5927\u6d6a\u6f6e\uff0c\u7b14\u8005\u6240\u5728\u7684\u516c\u53f8\u4e5f\u5f00\u59cb\u5c06\u6709\u4e9b\u9700\u6c42\u8f6c\u79fb\u5230\u5fae\u4fe1\u5c0f\u7a0b\u5e8f\u4e0a\u3002\u63a5\u4e0b\u6765\u5c06\u4ee5\u51e0\u7bc7\u6587\u7ae0\u5c06\u6700\u8fd1\u7684\u4e00\u4e2a<span style=\"font-family:Consolas, Inconsolata, Courier, monospace\">\u65e5\u5386\u6253\u5361<\/span>\u5c0f\u7a0b\u5e8f\u7684\u5f00\u53d1\u8fc7\u7a0b\u4ee5\u53ca\u9047\u5230\u7684\u95ee\u9898\u548c\u5927\u5bb6\u505a\u4e2a\u5206\u4eab\u3002<\/span><\/span><\/h3>\n<p>\u76f8\u5173\u514d\u8d39\u5b66\u4e60\u63a8\u8350\uff1a<\/p>\n<h4><span style=\"font-size:16px\">\uff08\u4e00\uff09\u5fae\u4fe1\u5f00\u53d1\u8005\u5de5\u5177<\/span><\/h4>\n<p style=\"text-align:left\">\u5c0f\u7a0b\u5e8f\u56e2\u961f\u63a8\u51fa\u4e86\u81ea\u5df1\u7684\u5f00\u53d1\u5de5\u5177-\u5fae\u4fe1\u5f00\u53d1\u8005\u5de5\u5177\uff0c\u76ee\u524d\u5fae\u4fe1\u5f00\u53d1\u8005\u5de5\u5177\u4efb\u7136\u5728\u4e0d\u65ad\u7684\u5b8c\u5584\u4e2d\uff0c\u5728\u5f00\u53d1\u5c0f\u7a0b\u5e8f\u65f6\u7ecf\u5e38\u8981\u4e0d\u65ad\u7684\u66f4\u65b0\u3002\u8bba\u575b\u4e0a\u5410\u69fd\u7684\u6587\u7ae0\u4e5f\u662f\u4e00\u5927\u5806\uff0c\u5b58\u5728\u5f88\u591abug\uff0c\u7b14\u8005\u5728\u5f00\u53d1\u8fc7\u7a0b\u4e2d\u4e5f\u662f\u88ab\u5b83\u5751\u8fc7\u3002\u7b14\u8005\u662f\u5b89\u5353\u5f00\u53d1\u8005\uff0c\u4e60\u60ef\u4e8e\u8fd9\u79cd\u53ef\u89c6\u5316\u7684\u7f16\u7a0b\uff0c\u6240\u4ee5\u6ca1\u6709\u9009\u62e9Webstrom\u6216\u8005\u5176\u4ed6\u5f00\u53d1\u5de5\u5177\uff0c\u63a5\u4e0b\u6765\u5c06\u4ecb\u7ecd\u5fae\u4fe1\u5f00\u53d1\u8005\u5de5\u5177\u57fa\u672c\u529f\u80fd<span style=\"font-size:14px\">\u3002<\/span><\/p>\n<p><span style=\"text-align:left\"><span style=\"font-size:14px\"><img decoding=\"async\" src=\"https:\/\/img.php.cn\/upload\/article\/000\/000\/052\/71c6817de426611231d45a4d3070f7da-0.jpg\" class=\"aligncenter\" title=\"\u5fae\u4fe1\u5c0f\u7a0b\u5e8f\u5f00\u53d1\uff08\u4e00\uff09\u4ecb\u7ecd\u5fae\u4fe1\u5f00\u53d1\u8005\u5de5\u5177\u4ee5\u53ca\u5c0f\u7a0b\u5e8f\u6846\u67b6\u63d2\u56fe1\" alt=\"\u5fae\u4fe1\u5c0f\u7a0b\u5e8f\u5f00\u53d1\uff08\u4e00\uff09\u4ecb\u7ecd\u5fae\u4fe1\u5f00\u53d1\u8005\u5de5\u5177\u4ee5\u53ca\u5c0f\u7a0b\u5e8f\u6846\u67b6\u63d2\u56fe1\" \/><\/span><\/span><\/p>\n<ol>\n<li><span style=\"font-size:14px\">\u673a\u578b\u9009\u62e9\uff1a\u5c0f\u7a0b\u5e8f\u4ee5<span style=\"font-family:Consolas, Inconsolata, Courier, monospace\"><span>IPhone6<\/span><\/span>\u7684\u5c4f\u5e55\u5c3a\u5bf8\u4e3a\u8bbe\u8ba1\u6807\u51c6\uff0c\u8ba9UI\u5c0f\u59d0\u59d0\u6309\u7167<span style=\"font-family:Consolas, Inconsolata, Courier, monospace\">IPhone6<\/span>\u5c4f\u5e55\u5c3a\u5bf8\u6765\u5207\u56fe\u3002<\/span><\/li>\n<li><span style=\"font-size:14px\">\u9884\u89c8\u754c\u9762\uff1a\u5199\u597d\u89c6\u56fe\u5e03\u5c40\u540e\u70b9\u51fb\u7f16\u8bd1\uff0c\u89c6\u56fe\u754c\u9762\u5237\u65b0\u663e\u793a<\/span><\/li>\n<li><span style=\"font-size:14px\">\u8fdc\u7a0b\u8c03\u8bd5\uff1a\u624b\u673a\u7aef\u548cPC\u7aef\u5f00\u53d1\u5de5\u5177\u8054\u8c03\uff08\u975e\u5e38\u5b9e\u7528\uff09<\/span><\/li>\n<li><span style=\"font-size:14px\">\u4e0a\u4f20\u4ee3\u7801\uff1a\u4e0a\u4f20\u5230\u817e\u8baf\u670d\u52a1\u5668\uff0c\u63d0\u4ea4\u5ba1\u6838\u5fc5\u7ecf\u6b65\u9aa4\u3002\u53ef\u4ee5\u586b\u5199\u7248\u672c\u53f7\u548c\u5907\u6ce8\u4fe1\u606f<\/span><\/li>\n<li><span style=\"font-size:14px\">5-1\uff1a\u4ee3\u7801\u4f53\u79ef\uff0c\u5fae\u4fe1\u9650\u5236&nbsp;<span style=\"font-family:Consolas, Inconsolata, Courier, monospace\">2M&nbsp;<\/span>\u4ee5\u5185\u3002 &nbsp;5-2\uff1aES\u8bed\u6cd5\u8f6c\u6362\uff0c\u5f00\u53d1\u4e2d\u4e00\u822c\u4e0d\u6821\u9a8c\u5408\u6cd5\u57df\u540d\u4fe1\u606f \u30025-3\uff1a\u57df\u540d\u4fe1\u606f\uff1a\u5c0f\u7a0b\u5e8f\u540e\u53f0\u8981\u505a\u914d\u7f6e\u670d\u52a1\u5668\u57df\u540d\uff0c\u6709<span style=\"font-family:Consolas, Inconsolata, Courier, monospace;color:#c7254e\"><span>request&nbsp;<\/span><\/span>\u57df\u540d\uff0c<span style=\"font-family:Consolas, Inconsolata, Courier, monospace\">socket&nbsp;<\/span>\u57df\u540d\u4ee5\u53ca<span style=\"font-family:Consolas, Inconsolata, Courier, monospace\">uploadFile<\/span>\u548c<span style=\"font-family:Consolas, Inconsolata, Courier, monospace\">downloadFile<\/span>\u57df\u540d\u3002<span style=\"color:#990000\">\u6ce8\u610f\uff1a<\/span><span style=\"color:#000000\">\u57df\u540d\u5c0f\u7a0b\u5e8f\u8981\u6c42\u5fc5\u987b\u662f<\/span><span style=\"color:#cc0000\">https&nbsp;<\/span><\/span><\/li>\n<li><span><span style=\"font-size:14px\">\u63a7\u5236\u53f0\uff1a\u6253\u5370\u8f93\u51fa\u4fe1\u606f\uff0c\u65b9\u4fbf\u8c03\u8bd5<\/span><\/span><\/li>\n<li><span><span style=\"font-size:14px\">\u8d44\u6e90\u6587\u4ef6\uff1a\u5bf9\u5e94\u9879\u76ee\u7684\u6587\u4ef6\u76ee\u5f55\uff0c\u4e00\u822c\u53ef\u4ee5\u5728\u8fd9\u91cc\u8fdb\u884c<span style=\"font-family:Consolas, Inconsolata, Courier, monospace\">\u65ad\u70b9\u8c03\u8bd5<\/span><\/span><\/span><\/li>\n<li><span style=\"font-size:14px\"><span style=\"color:#000000\">\u672c\u5730\u6570\u636e\u5b58\u50a8\uff1a\u663e\u793a\u7684\u662f\u672c\u5730\u5b58\u50a8\u7684\u6570\u636e\uff0c\u5bf9\u5e94\u7684\u76f8\u5173API\u662f<\/span><span style=\"font-family:Consolas, Inconsolata, Courier, monospace;color:#c7254e\"><span>wx.setStorageSync(key,data)<\/span><\/span><\/span><\/li>\n<li><span style=\"color:#000000\"><span style=\"font-size:14px\">\u89c6\u56fe\u8c03\u8bd5\uff1a\u6807\u7ec4\u4ef6\u4ee5<span>\u5b50\u7236\u5c42\u7ea7\u7ed3\u6784\u5448\u73b0\uff0c\u65b9\u4fbf\u8c03\u8bd5\u3002<\/span><\/span><\/span><\/li>\n<\/ol>\n<p style=\"text-align:left\"><span style=\"font-size:14px\">\u4ee5\u4e0a\u5c31\u662f\u5728\u5f00\u53d1\u8fc7\u7a0b\u4e2d\u5fae\u4fe1\u5f00\u53d1\u8005\u5de5\u5177\u5e38\u7528\u5230\u7684\u529f\u80fd\uff0c\u5fae\u4fe1<span style=\"text-align:left\">\u5f00\u53d1\u8005\u5de5\u5177\u4e5f\u5728\u4e0d\u65ad\u7684\u5b8c\u5584\uff0c<span style=\"text-align:left\">\u4e3a\u4e86\u4ee5\u540e\u66f4\u597d\u7684\u63d0\u5347\u5f00\u53d1\u6548\u7387\uff0c<\/span>\u4e5f\u9700\u8981\u6211\u4eec\u5728\u5f00\u53d1\u8fc7\u7a0b\u4e2d\u5c06\u9047\u5230\u7684\u95ee\u9898\u4e0d\u65ad\u7684\u53cd\u9988\u7ed9\u5c0f\u7a0b\u5e8f\u56e2\u961f\u505a\u4f18\u5316\uff0c\u5e0c\u671b\u5927\u5bb6\u62b1\u7740\u5305\u5bb9\u7684\u5fc3\u6001\u3002\u5f00\u53d1\u8fc7\u7a0b\u4e2d\u5927\u5bb6\u4e5f\u53ef\u4ee5\u4f9d\u7167\u81ea\u5df1\u7684\u4e60\u60ef\u9009\u62e9\u5176\u4ed6\u7684\u5f00\u53d1\u5de5\u5177\u3002<\/span><\/span><\/p>\n<p style=\"text-align: left\"><span style=\"font-weight:bold\"><span style=\"font-size:16px\">\uff08\u4e8c\uff09\u5c0f\u7a0b\u5e8f\u6846\u67b6\u4ee5\u53ca\u76ee\u5f55\u7ed3\u6784\u4ecb\u7ecd<\/span><\/span><\/p>\n<p><span style=\"text-align:left\"><span style=\"font-size:14px\"><img decoding=\"async\" src=\"https:\/\/img.php.cn\/upload\/article\/000\/000\/052\/71c6817de426611231d45a4d3070f7da-1.png\" class=\"aligncenter\" title=\"\u5fae\u4fe1\u5c0f\u7a0b\u5e8f\u5f00\u53d1\uff08\u4e00\uff09\u4ecb\u7ecd\u5fae\u4fe1\u5f00\u53d1\u8005\u5de5\u5177\u4ee5\u53ca\u5c0f\u7a0b\u5e8f\u6846\u67b6\u63d2\u56fe2\" alt=\"\u5fae\u4fe1\u5c0f\u7a0b\u5e8f\u5f00\u53d1\uff08\u4e00\uff09\u4ecb\u7ecd\u5fae\u4fe1\u5f00\u53d1\u8005\u5de5\u5177\u4ee5\u53ca\u5c0f\u7a0b\u5e8f\u6846\u67b6\u63d2\u56fe2\" \/><\/span><\/span><\/p>\n<ul>\n<li> <span style=\"font-size:14px\">&nbsp;\u903b\u8f91\u5c42\n<p><\/span><\/p>\n<p style=\"line-height:2;margin-bottom:.85em;letter-spacing:.2px\"><span style=\"font-size:14px\">\u5c0f\u7a0b\u5e8f\u5f00\u53d1\u6846\u67b6\u7684\u903b\u8f91\u5c42\u7531 JavaScript \u7f16\u5199\u3002<span style=\"letter-spacing:.2px\">\u903b\u8f91\u5c42\u5c06\u6570\u636e\u8fdb\u884c\u5904\u7406\u540e\u53d1\u9001\u7ed9\u89c6\u56fe\u5c42\uff0c\u540c\u65f6\u63a5\u53d7\u89c6\u56fe\u5c42\u7684\u4e8b\u4ef6\u53cd\u9988\u3002\u903b\u8f91\u5c42\u5bf9\u5e94\u7684\u662fjs\u6587\u4ef6\uff0c\u5728\u6bcf\u4e2a\u9875\u9762\u7684js\u6587\u4ef6\u4e2d\uff0c\u7cfb\u7edf\u63d0\u4f9b\u4e86\u4e00\u7cfb\u5217\u7684\u65b9\u6cd5\u5982\uff1a\u9875\u9762\u751f\u547d\u5468\u671f<span style=\"font-family:Consolas, Inconsolata, Courier, monospace\">onLoad()<\/span>,<span style=\"letter-spacing:.2px;font-family:Consolas, Inconsolata, Courier, monospace\">onShow()<\/span><span style=\"letter-spacing:.2px\">,<\/span><span style=\"letter-spacing:.2px;font-family:Consolas, Inconsolata, Courier, monospace\">onHide()<\/span><span style=\"letter-spacing:.2px\">,<\/span>\u7b49\uff0c\u4e0b\u62c9\u5237\u65b0<span style=\"font-family:Consolas, Inconsolata, Courier, monospace;letter-spacing:.2px\">onPullDownRefresh()<\/span>\uff0c\u9875\u9762\u5230\u5e95\u90e8\uff08\u4e0a\u62c9\u52a0\u8f7d\uff09<span style=\"font-family:Consolas, Inconsolata, Courier, monospace;letter-spacing:.2px\">onReachBottom()<\/span>\u65b9\u6cd5\uff0c\u5206\u4eab\u529f\u80fd<span style=\"font-family:Consolas, Inconsolata, Courier, monospace;letter-spacing:.2px\">onShareAppMessage()<\/span>\u7b49\u3002<\/span><\/span><\/p>\n<p> <span style=\"font-size:14px\"><br \/><\/span> <\/li>\n<li> <span style=\"font-size:14px\">\u89c6\u56fe\u5c42\n<p><\/span><\/p>\n<p style=\"margin-bottom:.85em;line-height:2;letter-spacing:.2px\"><span style=\"font-size:14px\">\u6846\u67b6\u7684\u89c6\u56fe\u5c42\u7531 <span style=\"font-family:Consolas, Inconsolata, Courier, monospace;letter-spacing:.2px\">wxml&nbsp;<\/span>\u4e0e <span style=\"letter-spacing:.2px\">&nbsp;<\/span><span style=\"letter-spacing:.2px;font-family:Consolas, Inconsolata, Courier, monospace\">wxss&nbsp;<\/span>\u7f16\u5199\uff0c\u7531\u7ec4\u4ef6\u6765\u8fdb\u884c\u5c55\u793a\u3002<span style=\"letter-spacing:.2px\">\u5c06\u903b\u8f91\u5c42\u7684\u6570\u636e\u53cd\u5e94\u6210\u89c6\u56fe\uff0c\u540c\u65f6\u5c06\u89c6\u56fe\u5c42\u7684\u4e8b\u4ef6\u53d1\u9001\u7ed9\u903b\u8f91\u5c42\u3002<span style=\"letter-spacing:.2px\"><span style=\"letter-spacing:.2px\">&nbsp;<\/span><span style=\"letter-spacing:.2px;font-family:Consolas, Inconsolata, Courier, monospace\">wxml&nbsp;<\/span><\/span>\u7531\u5c0f\u7a0b\u5e8f\u63d0\u4f9b\u7684\u7ec4\u4ef6\u7ec4\u6210\uff0c<span style=\"font-family:Consolas, Inconsolata, Courier, monospace;letter-spacing:.2px\">wxss&nbsp;<\/span>\u662f<span style=\"font-family:Consolas, Inconsolata, Courier, monospace;letter-spacing:.2px\">css&nbsp;<\/span>\u6837\u5f0f\u3002<\/p>\n<p><\/span><\/span><\/p>\n<\/li>\n<li> <span style=\"font-size:14px\">app\u6587\u4ef6\n<p><span style=\"font-family:Consolas, Inconsolata, Courier, monospace;letter-spacing:.2px\">app.json&nbsp;<\/span><\/span><span style=\"letter-spacing:.2px\"><span style=\"font-size:14px\"><span>\u6587\u4ef6\u7528\u6765\u5bf9\u5fae\u4fe1\u5c0f\u7a0b\u5e8f\u8fdb\u884c\u5168\u5c40\u914d\u7f6e\uff0c\u51b3\u5b9a\u9875\u9762\u6587\u4ef6\u7684\u8def\u5f84\u3001\u7a97\u53e3\u8868\u73b0\u3001\u8bbe\u7f6e\u7f51\u7edc\u8d85\u65f6\u65f6\u95f4\u3001\u8bbe\u7f6e\u591a tab \u7b49\u3002\u9875\u9762\u7684json\u6587\u4ef6\u4e00\u822c\u7528\u6765\u914d\u7f6e\u5f53\u524d\u9875\u9762\u7684\u7a97\u53e3\u8868\u73b0\u3002<\/span><span style=\"letter-spacing:.2px\"><span style=\"font-family:Consolas, Inconsolata, Courier, monospace;letter-spacing:.2px\">app.js<\/span>&nbsp;<\/span><span>\u7528\u6765\u63d0\u4f9b\u5168\u5c40\u53d8\u91cf\uff0c\u5982baseUrl\u3002<\/span><span style=\"letter-spacing:.2px\"><span style=\"font-family:Consolas, Inconsolata, Courier, monospace;letter-spacing:.2px\">app.wxss<\/span><\/span><\/span><span><span style=\"font-size:14px\">&nbsp;\u63d0\u4f9b\u5168\u5c40\u7684css\u6837\u5f0f<\/span><\/p>\n<p><\/span><\/span> <\/p>\n<pre>{\n  \"pages\": [                    \/\/\u9875\u9762\u7684\u8def\u5f84(\u5728\u6b64\u5904\u53ef\u5feb\u6377\u521b\u5efa\u9875\u9762)\n    \"pages\/index\/index\",\n    \"pages\/logs\/index\"\n  ],\n  \"window\": {                   \/\/\u89c6\u56fe\u7a97\u53e3\n    \"navigationBarTitleText\": \"Demo\"\n  },\n  \"tabBar\": {                   \/\/\u5e95\u90e8tab\n    \"list\": [{\n      \"pagePath\": \"pages\/index\/index\",\n      \"text\": \"\u9996\u9875\"\n    }, {\n      \"pagePath\": \"pages\/logs\/logs\",\n      \"text\": \"\u65e5\u5fd7\"\n    }]\n  },\n  \"networkTimeout\": {           \/\/\u8bbe\u7f6e\u662f\u5426\u8d85\u65f6\n    \"request\": 10000,\n    \"downloadFile\": 10000\n  },\n  \"debug\": true\n}<\/pre>\n<p> \u767b\u5f55\u540e\u590d\u5236 <\/li>\n<li><span style=\"letter-spacing:.2px\"><span style=\"font-size:14px\"><span style=\"font-family:Consolas, Inconsolata, Courier, monospace;letter-spacing:.2px\">utils\/.json&nbsp;<\/span>\n<p>\u7cfb\u7edf\u63d0\u4f9b\u7684\u5de5\u5177\u7c7b\uff0c\u4e00\u822c\u7f16\u5199\u516c\u5171\u7684\u65b9\u6cd5\u5bfc\u51fa\u65b9\u4fbf\u5176\u4ed6\u9875\u9762\u8c03\u7528\u3002<\/span><br \/><\/span><\/li>\n<\/ul>\n<ul><\/ul>\n<p><span style=\"text-align:left\"><strong><span style=\"font-size:16px\">\uff08\u4e09\uff09\u7ed3\u675f\u8bed<\/span><span style=\"font-size:14px\"><br \/><\/span><\/strong><\/span><\/p>\n<p><span style=\"font-size:14px\"><span style=\"text-align:left\"><strong>&nbsp; &nbsp;<\/strong><\/span><span style=\"text-align:left\">&nbsp;\u672c\u7bc7\u6587\u7ae0\u7b80\u5355\u7684\u4ecb\u7ecd\u4e86\u5fae\u4fe1\u5f00\u53d1\u8005\u5de5\u5177\u548c\u5c0f\u7a0b\u5e8f\u7684\u6846\u67b6\uff0c\u5fae\u4fe1\u7684\u5f00\u53d1\u6587\u6863\u5bf9\u76f8\u5173\u529f\u80fd\u7684\u4ecb\u7ecd\u5341\u5206\u7684\u8be6\u7ec6\u3002\u63a5\u4e0b\u6765\u5c06\u5f00\u59cb\u6211\u4eec\u7684\u65e5\u5386\u6253\u5361\u5c0f\u7a0b\u5e8f\u5f00\u53d1\u4e4b\u65c5\u3002<\/span><\/span><\/p>\n<blockquote><p>\n  \u76f8\u5173\u5b66\u4e60\u63a8\u8350\uff1a\u5c0f\u7a0b\u5e8f\u5f00\u53d1\u6559\u7a0b\n<\/p><\/blockquote>\n<p>\u4ee5\u4e0a\u5c31\u662f\u5fae\u4fe1\u5c0f\u7a0b\u5e8f\u5f00\u53d1\uff08\u4e00\uff09\u4ecb\u7ecd\u5fae\u4fe1\u5f00\u53d1\u8005\u5de5\u5177\u4ee5\u53ca\u5c0f\u7a0b\u5e8f\u6846\u67b6\u7684\u8be6\u7ec6\u5185\u5bb9\uff0c\u66f4\u591a\u8bf7\u5173\u6ce8\u7c73\u4e91\u5176\u5b83\u76f8\u5173\u6587\u7ae0\uff01<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u524d\u8a00 \u4e00\u76f4\u4e0d\u6e29\u4e0d\u706b\u7684\u5fae\u4fe1\u5c0f\u7a0b\u5e8f2018\u5e74\u8fce\u6765\u4e86\u7b2c\u4e8c\u6625\uff0c\u5728\u6211\u7684\u8bb0\u5fc6\u4e2d\u968f\u7740\u8df3\u4e00\u8df3\u5c0f\u6e38\u620f\u7684\u51fa\u73b0\uff0c\u4e00\u65f6\u95f4\u6570\u5343\u4e07\u7684\u5fae\u4fe1\u5c0f\u7a0b\u5e8f\u5982\u96e8\u540e\u6625\u7b0b\u822c\u51fa\u73b0\u5728\u6211\u4eec\u7684\u89c6\u7ebf\u91cc\u3002\u8ffd\u7740\u8fd9\u6ce2\u5927\u6d6a\u6f6e\uff0c\u7b14\u8005\u6240\u5728\u7684\u516c\u53f8\u4e5f\u5f00\u59cb\u5c06\u6709\u4e9b\u9700\u6c42\u8f6c\u79fb\u5230\u5fae\u4fe1\u5c0f\u7a0b\u5e8f\u4e0a\u3002\u63a5\u4e0b\u6765\u5c06\u4ee5\u51e0\u7bc7\u6587\u7ae0\u5c06\u6700\u8fd1\u7684\u4e00\u4e2a\u65e5\u5386\u6253\u5361\u5c0f\u7a0b\u5e8f\u7684\u5f00\u53d1\u8fc7\u7a0b\u4ee5\u53ca\u9047\u5230\u7684\u95ee\u9898\u548c\u5927\u5bb6\u505a\u4e2a\u5206\u4eab\u3002 \u76f8\u5173\u514d\u8d39\u5b66\u4e60\u63a8\u8350\uff1a \uff08\u4e00\uff09\u5fae\u4fe1\u5f00\u53d1\u8005\u5de5\u5177 \u5c0f\u7a0b\u5e8f\u56e2\u961f\u63a8\u51fa\u4e86\u81ea\u5df1\u7684\u5f00\u53d1\u5de5\u5177-\u5fae\u4fe1\u5f00\u53d1\u8005\u5de5\u5177\uff0c\u76ee\u524d\u5fae\u4fe1\u5f00\u53d1\u8005\u5de5\u5177\u4efb\u7136\u5728\u4e0d\u65ad\u7684\u5b8c\u5584\u4e2d\uff0c\u5728\u5f00\u53d1\u5c0f\u7a0b\u5e8f\u65f6\u7ecf\u5e38\u8981\u4e0d\u65ad\u7684\u66f4\u65b0\u3002\u8bba\u575b\u4e0a\u5410\u69fd\u7684\u6587\u7ae0\u4e5f\u662f\u4e00\u5927\u5806\uff0c\u5b58\u5728\u5f88\u591abug\uff0c\u7b14\u8005\u5728\u5f00\u53d1\u8fc7\u7a0b\u4e2d\u4e5f\u662f\u88ab\u5b83\u5751\u8fc7\u3002\u7b14\u8005\u662f\u5b89\u5353\u5f00\u53d1\u8005\uff0c\u4e60\u60ef\u4e8e\u8fd9\u79cd\u53ef\u89c6\u5316\u7684\u7f16\u7a0b\uff0c\u6240\u4ee5\u6ca1\u6709\u9009\u62e9Webstrom\u6216\u8005\u5176\u4ed6\u5f00\u53d1\u5de5\u5177\uff0c\u63a5\u4e0b\u6765\u5c06\u4ecb\u7ecd\u5fae\u4fe1\u5f00\u53d1\u8005\u5de5\u5177\u57fa\u672c\u529f\u80fd\u3002 \u673a\u578b\u9009\u62e9\uff1a\u5c0f\u7a0b\u5e8f\u4ee5IPhone6\u7684\u5c4f\u5e55\u5c3a\u5bf8\u4e3a\u8bbe\u8ba1\u6807\u51c6\uff0c\u8ba9UI\u5c0f\u59d0\u59d0\u6309\u7167IPhone6\u5c4f\u5e55\u5c3a\u5bf8\u6765\u5207\u56fe\u3002 \u9884\u89c8\u754c\u9762\uff1a\u5199\u597d\u89c6\u56fe\u5e03\u5c40\u540e\u70b9\u51fb\u7f16\u8bd1\uff0c\u89c6\u56fe\u754c\u9762\u5237\u65b0\u663e\u793a \u8fdc\u7a0b\u8c03\u8bd5\uff1a\u624b\u673a\u7aef\u548cPC\u7aef\u5f00\u53d1\u5de5\u5177\u8054\u8c03\uff08\u975e\u5e38\u5b9e\u7528\uff09 \u4e0a\u4f20\u4ee3\u7801\uff1a\u4e0a\u4f20\u5230\u817e\u8baf\u670d\u52a1\u5668\uff0c\u63d0\u4ea4\u5ba1\u6838\u5fc5\u7ecf\u6b65\u9aa4\u3002\u53ef\u4ee5\u586b\u5199\u7248\u672c\u53f7\u548c\u5907\u6ce8\u4fe1\u606f 5-1\uff1a\u4ee3\u7801\u4f53\u79ef\uff0c\u5fae\u4fe1\u9650\u5236&nbsp;2M&nbsp;\u4ee5\u5185\u3002 &nbsp;5-2\uff1aES\u8bed\u6cd5\u8f6c\u6362\uff0c\u5f00\u53d1\u4e2d\u4e00\u822c\u4e0d\u6821\u9a8c\u5408\u6cd5\u57df\u540d\u4fe1\u606f \u30025-3\uff1a\u57df\u540d\u4fe1\u606f\uff1a\u5c0f\u7a0b\u5e8f\u540e\u53f0\u8981\u505a\u914d\u7f6e\u670d\u52a1\u5668\u57df\u540d\uff0c\u6709request&nbsp;\u57df\u540d\uff0csocket&nbsp;\u57df\u540d\u4ee5\u53cauploadFile\u548cdownloadFile\u57df\u540d\u3002\u6ce8\u610f\uff1a\u57df\u540d\u5c0f\u7a0b\u5e8f\u8981\u6c42\u5fc5\u987b\u662fhttps&nbsp; \u63a7\u5236\u53f0\uff1a\u6253\u5370\u8f93\u51fa\u4fe1\u606f\uff0c\u65b9\u4fbf\u8c03\u8bd5 \u8d44\u6e90\u6587\u4ef6\uff1a\u5bf9\u5e94\u9879\u76ee\u7684\u6587\u4ef6\u76ee\u5f55\uff0c\u4e00\u822c\u53ef\u4ee5\u5728\u8fd9\u91cc\u8fdb\u884c\u65ad\u70b9\u8c03\u8bd5 \u672c\u5730\u6570\u636e\u5b58\u50a8\uff1a\u663e\u793a\u7684\u662f\u672c\u5730\u5b58\u50a8\u7684\u6570\u636e\uff0c\u5bf9\u5e94\u7684\u76f8\u5173API\u662fwx.setStorageSync(key,data) \u89c6\u56fe\u8c03\u8bd5\uff1a\u6807\u7ec4\u4ef6\u4ee5\u5b50\u7236\u5c42\u7ea7\u7ed3\u6784\u5448\u73b0\uff0c\u65b9\u4fbf\u8c03\u8bd5\u3002 \u4ee5\u4e0a\u5c31\u662f\u5728\u5f00\u53d1\u8fc7\u7a0b\u4e2d\u5fae\u4fe1\u5f00\u53d1\u8005\u5de5\u5177\u5e38\u7528\u5230\u7684\u529f\u80fd\uff0c\u5fae\u4fe1\u5f00\u53d1\u8005\u5de5\u5177\u4e5f\u5728\u4e0d\u65ad\u7684\u5b8c\u5584\uff0c\u4e3a\u4e86\u4ee5\u540e\u66f4\u597d\u7684\u63d0\u5347\u5f00\u53d1\u6548\u7387\uff0c\u4e5f\u9700\u8981\u6211\u4eec\u5728\u5f00\u53d1\u8fc7\u7a0b\u4e2d\u5c06\u9047\u5230\u7684\u95ee\u9898\u4e0d\u65ad\u7684\u53cd\u9988\u7ed9\u5c0f\u7a0b\u5e8f\u56e2\u961f\u505a\u4f18\u5316\uff0c\u5e0c\u671b\u5927\u5bb6\u62b1\u7740\u5305\u5bb9\u7684\u5fc3\u6001\u3002\u5f00\u53d1\u8fc7\u7a0b\u4e2d\u5927\u5bb6\u4e5f\u53ef\u4ee5\u4f9d\u7167\u81ea\u5df1\u7684\u4e60\u60ef\u9009\u62e9\u5176\u4ed6\u7684\u5f00\u53d1\u5de5\u5177\u3002 \uff08\u4e8c\uff09\u5c0f\u7a0b\u5e8f\u6846\u67b6\u4ee5\u53ca\u76ee\u5f55\u7ed3\u6784\u4ecb\u7ecd &nbsp;\u903b\u8f91\u5c42 \u5c0f\u7a0b\u5e8f\u5f00\u53d1\u6846\u67b6\u7684\u903b\u8f91\u5c42\u7531 JavaScript \u7f16\u5199\u3002\u903b\u8f91\u5c42\u5c06\u6570\u636e\u8fdb\u884c\u5904\u7406\u540e\u53d1\u9001\u7ed9\u89c6\u56fe\u5c42\uff0c\u540c\u65f6\u63a5\u53d7\u89c6\u56fe\u5c42\u7684\u4e8b\u4ef6\u53cd\u9988\u3002\u903b\u8f91\u5c42\u5bf9\u5e94\u7684\u662fjs\u6587\u4ef6\uff0c\u5728\u6bcf\u4e2a\u9875\u9762\u7684js\u6587\u4ef6\u4e2d\uff0c\u7cfb\u7edf\u63d0\u4f9b\u4e86\u4e00\u7cfb\u5217\u7684\u65b9\u6cd5\u5982\uff1a\u9875\u9762\u751f\u547d\u5468\u671fonLoad(),onShow(),onHide(),\u7b49\uff0c\u4e0b\u62c9\u5237\u65b0onPullDownRefresh()\uff0c\u9875\u9762\u5230\u5e95\u90e8\uff08\u4e0a\u62c9\u52a0\u8f7d\uff09onReachBottom()\u65b9\u6cd5\uff0c\u5206\u4eab\u529f\u80fdonShareAppMessage()\u7b49\u3002 \u89c6\u56fe\u5c42 \u6846\u67b6\u7684\u89c6\u56fe\u5c42\u7531 wxml&nbsp;\u4e0e &nbsp;wxss&nbsp;\u7f16\u5199\uff0c\u7531\u7ec4\u4ef6\u6765\u8fdb\u884c\u5c55\u793a\u3002\u5c06\u903b\u8f91\u5c42\u7684\u6570\u636e\u53cd\u5e94\u6210\u89c6\u56fe\uff0c\u540c\u65f6\u5c06\u89c6\u56fe\u5c42\u7684\u4e8b\u4ef6\u53d1\u9001\u7ed9\u903b\u8f91\u5c42\u3002&nbsp;wxml&nbsp;\u7531\u5c0f\u7a0b\u5e8f\u63d0\u4f9b\u7684\u7ec4\u4ef6\u7ec4\u6210\uff0cwxss&nbsp;\u662fcss&nbsp;\u6837\u5f0f\u3002 app\u6587\u4ef6 app.json&nbsp;\u6587\u4ef6\u7528\u6765\u5bf9\u5fae\u4fe1\u5c0f\u7a0b\u5e8f\u8fdb\u884c\u5168\u5c40\u914d\u7f6e\uff0c\u51b3\u5b9a\u9875\u9762\u6587\u4ef6\u7684\u8def\u5f84\u3001\u7a97\u53e3\u8868\u73b0\u3001\u8bbe\u7f6e\u7f51\u7edc\u8d85\u65f6\u65f6\u95f4\u3001\u8bbe\u7f6e\u591a tab \u7b49\u3002\u9875\u9762\u7684json\u6587\u4ef6\u4e00\u822c\u7528\u6765\u914d\u7f6e\u5f53\u524d\u9875\u9762\u7684\u7a97\u53e3\u8868\u73b0\u3002app.js&nbsp;\u7528\u6765\u63d0\u4f9b\u5168\u5c40\u53d8\u91cf\uff0c\u5982baseUrl\u3002app.wxss&nbsp;\u63d0\u4f9b\u5168\u5c40\u7684css\u6837\u5f0f { &#8220;pages&#8221;: [ \/\/\u9875\u9762\u7684\u8def\u5f84(\u5728\u6b64\u5904\u53ef\u5feb\u6377\u521b\u5efa\u9875\u9762) &#8220;pages\/index\/index&#8221;, &#8220;pages\/logs\/index&#8221; ], &#8220;window&#8221;: { \/\/\u89c6\u56fe\u7a97\u53e3 &#8220;navigationBarTitleText&#8221;: &#8220;Demo&#8221; }, &#8220;tabBar&#8221;: { \/\/\u5e95\u90e8tab &#8220;list&#8221;: [{ &#8220;pagePath&#8221;: &#8220;pages\/index\/index&#8221;, &#8220;text&#8221;: &#8220;\u9996\u9875&#8221; }, { &#8220;pagePath&#8221;: [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[19],"tags":[],"class_list":["post-33957","post","type-post","status-publish","format-standard","hentry","category-19"],"_links":{"self":[{"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/posts\/33957","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/comments?post=33957"}],"version-history":[{"count":0,"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/posts\/33957\/revisions"}],"wp:attachment":[{"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/media?parent=33957"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/categories?post=33957"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/tags?post=33957"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}