{"id":2999,"date":"2023-08-16T18:39:03","date_gmt":"2023-08-16T10:39:03","guid":{"rendered":"https:\/\/www.yimenyun.cn\/emen\/?p=2999"},"modified":"2023-08-16T18:39:03","modified_gmt":"2023-08-16T10:39:03","slug":"vue%e5%9c%a8%e7%ba%bf%e7%94%9f%e6%88%90app%e8%a6%81%e6%80%8e%e4%b9%88%e5%81%9a%ef%bc%9f","status":"publish","type":"post","link":"https:\/\/www.yimenyun.cn\/emen\/2999\/","title":{"rendered":"vue\u5728\u7ebf\u751f\u6210app\u8981\u600e\u4e48\u505a\uff1f"},"content":{"rendered":"

\u6807\u9898\uff1aVue\u5728\u7ebf\u751f\u6210APP\uff1a\u539f\u7406\u53ca\u8be6\u7ec6\u4ecb\u7ecd<\/p>\n

\u7b80\u4ecb\uff1a\u672c\u6587\u5c06\u5e26\u60a8\u4e86\u89e3\u5982\u4f55\u5229\u7528Vue.js\u5f00\u53d1\u4e00\u4e2a\u5728\u7ebf\u751f\u6210\u539f\u751fAPP\u7684\u7f51\u7ad9\uff0c\u5e76\u89e3\u6790Vue.js\u751f\u6210APP\u7684\u4e3b\u8981\u539f\u7406\u3002<\/p>\n

\u5185\u5bb9\u6982\u8981\uff1a<\/p>\n

1. Vue.js \u7b80\u8ff0<\/p>\n

2. \u5728\u7ebf\u751f\u6210APP\u7684\u6d41\u884c\u6280\u672f<\/p>\n

3. Vue\u5728\u7ebf\u751f\u6210APP\u7684\u539f\u7406<\/p>\n

4. Vue\u5728\u7ebf\u751f\u6210APP\u7684\u6b65\u9aa4<\/p>\n

5. \u53ef\u7528\u7684\u9879\u76ee\u6a21\u677f<\/p>\n

6. \u603b\u7ed3<\/p>\n

\u6b63\u6587\uff1a<\/p>\n

1. Vue.js \u7b80\u8ff0<\/p>\n

Vue.js\u662f\u4e00\u4e2a\u7528\u4e8e\u6784\u5efa\u7528\u6237\u754c\u9762\u7684\u6e10\u8fdb\u5f0fJavaScript\u6846\u67b6\u3002\u4e0e\u5176\u4ed6\u5927\u578b\u6846\u67b6\u4e0d\u540c\uff0cVue\u4e13\u6ce8\u4e8e\u63d0\u4f9b\u4e00\u4e2a\u6613\u4e8e\u4e0a\u624b\u7684\u89e3\u51b3\u65b9\u6848\uff0c\u4f7f\u5f00\u53d1\u8005\u80fd\u591f\u4e13\u6ce8\u5e94\u7528\u7a0b\u5e8f\u7684UI\u548c\u903b\u8f91\u5206\u9694\uff0c\u66f4\u5bb9\u6613\u5730\u5f00\u53d1\u548c\u7ef4\u62a4\u5e94\u7528\u7a0b\u5e8f\u3002<\/p>\n

2. \u5728\u7ebf\u751f\u6210APP\u7684\u6d41\u884c\u6280\u672f<\/p>\n

Cordova\u548cIonic\u662f\u4e24\u4e2a\u5e38\u7528\u7684\u8de8\u5e73\u53f0\u79fb\u52a8\u5e94\u7528\u5f00\u53d1\u5e73\u53f0\uff0c\u5b83\u4eec\u80fd\u5c06Vue.js\u7b49Web\u6280\u672f\u5c01\u88c5\u6210\u5177\u6709\u539f\u751f\u4f53\u9a8c\u7684APP\u3002\u8fd9\u6837\uff0c\u5f00\u53d1\u8005\u65e0\u9700\u7f16\u5199\u591a\u5957\u4ee3\u7801\uff0c\u5c31\u80fd\u6ee1\u8db3\u591a\u4e2a\u5e73\u53f0\u7684\u9700\u6c42\u3002<\/p>\n

3. Vue\u5728\u7ebf\u751f\u6210APP\u7684\u539f\u7406<\/p>\n

\u5728\u7ebf\u751f\u6210APP\u7684\u8fc7\u7a0b\u4f7f\u7528\u4e86\u4e00\u79cd\u53eb\u505aWebView\u7684\u6280\u672f\uff0c\u5373\u5c06\u4e00\u4e2aWeb\u9875\u9762\u5d4c\u5165\u5230\u539f\u751fAPP\u4e2d\u3002\u8fd9\u4e2aWeb\u9875\u9762\u662f\u901a\u8fc7Vue.js\u6846\u67b6\u521b\u5efa\u7684\uff0c\u5176\u4e2d\u5305\u542b\u4e86\u6211\u4eec\u6240\u9700\u7684\u529f\u80fd\u3002\u5728\u6b64\u57fa\u7840\u4e0a\uff0c\u7ed3\u5408Vue.js\u7684\u751f\u6001\u7cfb\u7edf\uff0c\u6211\u4eec\u53ef\u4ee5\u901a\u8fc7\u63d2\u4ef6\u548c\u6269\u5c55\u5feb\u901f\u5b9e\u73b0\u6240\u9700\u529f\u80fd\u3002\u6700\u540e\u901a\u8fc7Cordova\u6216Ionic\u7b49\u5de5\u5177\u5c06Vue\u9879\u76ee\u6253\u5305\u6210\u539f\u751f\u5b89\u88c5\u5305\uff0c\u5b9e\u73b0\u4e00\u6b21\u5f00\u53d1\uff0c\u591a\u7aef\u8fd0\u884c\u3002<\/p>\n

4. Vue\u5728\u7ebf\u751f\u6210APP\u7684\u6b65\u9aa4<\/p>\n

\u4ee5\u4e0b\u662f\u4e00\u4e2a\u7b80\u5355\u7684Vue\u5728\u7ebf\u751f\u6210APP\u7684\u6b65\u9aa4\u4ecb\u7ecd\uff1a<\/p>\n

a. \u521d\u59cb\u5316Vue\u9879\u76ee<\/p>\n

\u9996\u5148\uff0c\u5b89\u88c5Vue CLI\uff0c\u521b\u5efa\u4e00\u4e2a\u65b0\u7684Vue\u9879\u76ee\uff0c\u7136\u540e\u5728\u9879\u76ee\u4e2d\u5b89\u88c5\u6240\u9700\u7684Vue\u63d2\u4ef6\u3002<\/p>\n

b. \u5bfc\u5165Cordova\u6216Ionic<\/p>\n

\u63a5\u4e0b\u6765\uff0c\u5c06Cordova\u6216Ionic\u96c6\u6210\u5230Vue\u9879\u76ee\u4e2d\uff0c\u8fd9\u5c06\u5728Vue\u9879\u76ee\u4e2d\u751f\u6210\u539f\u751fAPP\u7684<\/p>\n

<\/figure>\n<\/p>\n

\u57fa\u5740\u3002<\/p>\n

c. \u7f16\u5199\u4e1a\u52a1\u4ee3\u7801<\/p>\n

\u5f00\u53d1\u8fc7\u7a0b\u4e2d\uff0c\u4f60\u9700\u8981\u7f16\u5199\u5408\u9002\u7684\u7ec4\u4ef6\u548c\u9875\u9762\uff0c\u4f7f\u9879\u7f51\u9875\u7248\u7684\u6e38\u620f\u600e\u4e48\u751f\u6210app<\/a>\u76ee\u8fbe\u5230\u9884\u671f\u7684\u529f\u80fd\u3002\u5728\u8fd9\u4e2a\u8fc7\u7a0b\u4e2d\uff0c\u4f60\u53ef\u4ee5\u5229\u7528Vue.js\u7684\u7279\u6027\uff0c\u4e3a\u539f\u751fAPP\u6dfb\u52a0\u7279\u6b8a\u6548\u679c\u3001\u52a8\u753b\u7b49\u3002<\/p>\n

d. \u6267\u884c\u6253\u5305\u8fc7\u7a0b<\/p>\n

\u5f53\u4f60\u5b8c\u6210Vue.js\u9879\u76ee\u7684\u5f00\u53d1\uff0c\u5c31\u53ef\u4ee5\u901a\u8fc7\u5de5\u5177\u6253\u5305\u6210\u539f\u751fAPP\u3002\u8fd9\u5c06\u751f\u6210\u5bf9\u5e94\u5e73\u53f0\u7684\u5b89\u88c5\u5305\uff0c\u5982Android\u7684APK\u6587\u4ef6\u548ciOS\u7684IPA\u6587\u4ef6\u3002<\/p>\n

e. \u53d1\u5e03\u4e0e\u5206\u4eab<\/p>\n

\u6700\u540e\uff0c\u5c06\u751f\u6210\u597d\u7684APP\u53d1\u5e03\u5230\u5e94\u7528\u5546\u5e97\u6216\u79c1\u4eba\u670d\u52a1\u5668\u4e0a\uff0c\u4f9b\u7528\u6237\u4e0b\u8f7d\u548c\u5b89\u88c5\u3002<\/p>\n

5. \u53ef\u7528\u7684\u9879\u76ee\u6a21\u677f<\/p>\n

\u4e3a\u4e86\u65b9\u4fbf\u5f00\u53d1\u8005\u5feb\u901f\u5165\u95e8\uff0c\u5728Github\u4e0a\u6709\u8bb8\u591aVue\u5728\u7ebf\u751f\u6210APP\u7684\u6a21\u677f\u3002\u4f8b\u5982\uff1a`vue-cordova-teappicon\u4e00\u952e\u751f\u6210\u7f51\u7ad9<\/a>mplates` \u548c `vue-ionic-starter`\u3002\u8fd9\u4e9b\u6a21\u677f\u5df2\u7ecf\u642d\u5efa\u597d\u57fa\u7840\u73af\u5883\uff0c\u5e76\u96c6\u6210\u4e86\u4e00\u4e9b\u5e38\u7528\u63d2\u4ef6\uff0c\u53ef\u4ee5\u8282\u7701\u5f00\u53d1\u8005\u7684\u65f6\u95f4\u3002<\/p>\n

6. \u603b\u7ed3<\/p>\n

Vue\u5728\u7ebf\u751f\u6210APP\u63d0\u4f9b\u4e86\u4e00\u4e2a\u9ad8\u5ea6\u53ef\u81ea\u5b9a\u4e49\u3001\u8de8\u5e73\u53f0\u7684\u65b9\u5f0f\u6765\u5feb\u901f\u5f00\u53d1\u548c\u53d1\u5e03\u539f\u751f\u5e94\u7528\u7a0b\u5e8f\u3002\u901a\u8fc7Vue.js \u7684\u751f\u6001\u7cfb\u7edf\uff0c\u4f60\u53ef\u4ee5\u5feb\u901f\u6784\u5efa\u590d\u6742\u7684\u5e94\u7528\u7a0b\u5e8f\u3002\u540c\u65f6\uff0cCordova\u548cIonic\u7b49\u5de5\u5177\u7684\u652f\u6301\uff0c\u80fd\u4f7fAPP\u5177\u6709\u8f83\u9ad8\u7684\u539f\u751f\u4f53\u9a8c\u3002\u60f3\u8981\u8fdb\u4e00\u6b65\u4e86\u89e3\u7684\u5f00\u53d1\u8005\uff0c\u53ef\u4ee5\u6df1\u5165\u7814\u7a76Vue.js\u6587\u6863\u548c\u5728\u7ebf\u8bfe\u7a0b\uff0c\u4ee5\u638c\u63e1\u66f4\u591a\u9ad8\u7ea7\u7279\u6027\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"

\u6807\u9898\uff1aVue\u5728\u7ebf\u751f\u6210APP\uff1a\u539f\u7406\u53ca\u8be6\u7ec6\u4ecb\u7ecd\u7b80\u4ecb\uff1a\u672c\u6587\u5c06\u5e26\u60a8\u4e86\u89e3\u5982\u4f55\u5229\u7528Vue.js\u5f00\u53d1\u4e00\u4e2a\u5728\u7ebf\u751f\u6210\u539f\u751fAPP\u7684\u7f51\u7ad9\uff0c\u5e76\u89e3\u6790Vue.js\u751f\u6210APP\u7684\u4e3b\u8981\u539f\u7406\u3002\u5185\u5bb9\u6982\u8981\uff1a1. Vue.js \u7b80\u8ff02. \u5728<\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[4],"tags":[17,1231,921,6126,23],"topic":[],"class_list":{"0":"post-2999","1":"post","2":"type-post","3":"status-publish","4":"format-standard","5":"hentry","6":"category-appkf","7":"tag-17","8":"tag-1231","9":"tag-app","11":"tag-23"},"_links":{"self":[{"href":"https:\/\/www.yimenyun.cn\/emen\/wp-json\/wp\/v2\/posts\/2999","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.yimenyun.cn\/emen\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.yimenyun.cn\/emen\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.yimenyun.cn\/emen\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/www.yimenyun.cn\/emen\/wp-json\/wp\/v2\/comments?post=2999"}],"version-history":[{"count":0,"href":"https:\/\/www.yimenyun.cn\/emen\/wp-json\/wp\/v2\/posts\/2999\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.yimenyun.cn\/emen\/wp-json\/wp\/v2\/media?parent=2999"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.yimenyun.cn\/emen\/wp-json\/wp\/v2\/categories?post=2999"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.yimenyun.cn\/emen\/wp-json\/wp\/v2\/tags?post=2999"},{"taxonomy":"topic","embeddable":true,"href":"https:\/\/www.yimenyun.cn\/emen\/wp-json\/wp\/v2\/topic?post=2999"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}