﻿{"id":1995,"date":"2020-03-03T15:45:40","date_gmt":"2020-03-03T07:45:40","guid":{"rendered":"http:\/\/jilin.hydesign.tw\/?p=1995"},"modified":"2021-10-23T21:11:52","modified_gmt":"2021-10-23T13:11:52","slug":"vue-start","status":"publish","type":"post","link":"http:\/\/jilin.hydesign.tw\/index.php\/2020\/03\/03\/vue-start\/","title":{"rendered":"Vue-\u74b0\u5883\u5efa\u7acb"},"content":{"rendered":"\n<h3 class=\"wp-block-heading\">A <strong>\u5b89\u88ddbrew<\/strong><\/h3>\n\n\n\n<pre class=\"wp-block-code\"><code>\/usr\/bin\/ruby -e \"$(curl -fsSL https:\/\/raw.githubusercontent.com\/Homebrew\/install\/master\/install)\"\n\nbrew -v<\/code><\/pre>\n\n\n\n<h3 class=\"wp-block-heading\">B \u5b89\u88ddnodejs+npm<\/h3>\n\n\n\n<h4 class=\"wp-block-heading\">\u5efa\u8b70\u76f4\u63a5\u4e0b\u8f09\u5b89\u88dd<\/h4>\n\n\n\n<p><a href=\"https:\/\/nodejs.org\/en\/\">https:\/\/nodejs.org\/en\/<\/a><\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>brew install nodejs\n\u5378\u8f09 brew uninstall node\n\u67e5\u770b\u5b89\u88dd\u4f4d\u7f6e which node<\/code><\/pre>\n\n\n\n<h4 class=\"wp-block-heading\">\u67e5\u770b\u7248\u672c<\/h4>\n\n\n\n<pre class=\"wp-block-code\"><code>node -v\nnpm -v<\/code><\/pre>\n\n\n\n<h3 class=\"wp-block-heading\">C \u5b89\u88ddvue (\u6846\u67b6)<\/h3>\n\n\n\n<pre class=\"wp-block-code\"><code>npm install vue \n\u6216\u8df3\u904e\u6b64\u6b65\u9a5f\u76f4\u63a5\u5b89\u88ddvue-cli <\/code><\/pre>\n\n\n\n<h4 class=\"wp-block-heading\">\u5b89\u88ddvue-cli (\u5de5\u5177) <\/h4>\n\n\n\n<pre class=\"wp-block-code\"><code>npm install -g @vue\/cli (\u5b89\u88dd\u6700\u65b0\u7248\u672c) \u6216 npm install -g vue-cli\n\u5378\u8f09 npm uninstall -g @vue\/cli \u6216 npm uninstall vue-cli -g<\/code><\/pre>\n\n\n\n<h4 class=\"wp-block-heading\">\u6aa2\u67e5\u662f\u5426\u5b89\u88dd\u6210\u529f<\/h4>\n\n\n\n<pre class=\"wp-block-code\"><code>vue --version\nvue\nvue list<\/code><\/pre>\n\n\n\n<h4 class=\"wp-block-heading\">\u5275\u5efa\u5c08\u6848<\/h4>\n\n\n\n<pre class=\"wp-block-code\"><code>vue create [projectName]<\/code><\/pre>\n\n\n\n<pre class=\"wp-block-code\"><code>? Please pick a preset:(Use arrow keys)\n  default (babel, eslint)\n\u276f Manually select features\n\ndefaule : \u5305\u542b\u4e86\u57fa\u672c\u7684 Babel + ESLint preset\uff0c\nManually : \u81ea\u5df1\u624b\u52d5\u9078\u64c7<\/code><\/pre>\n\n\n\n<pre class=\"wp-block-code\"><code>cd  [projectName]\nnpm run serve\n\n\u9023\u7d50  http:\/\/localhost:8080<\/code><\/pre>\n\n\n\n<pre class=\"wp-block-code\"><code>\u767c\u4f48\u5230\u4f3a\u670d\u5668\u700f\u89bd npm run build<\/code><\/pre>\n","protected":false},"excerpt":{"rendered":"<p>A \u5b89\u88ddbrew B \u5b89\u88ddnodejs+npm \u5efa\u8b70\u76f4\u63a5\u4e0b\u8f09\u5b89\u88dd https:\/\/nodejs.org\/en\/&#46;&#46;&#46;<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[37,40,4],"tags":[],"class_list":["post-1995","post","type-post","status-publish","format-standard","hentry","category-vue","category-web-frame","category-notes"],"_links":{"self":[{"href":"http:\/\/jilin.hydesign.tw\/index.php\/wp-json\/wp\/v2\/posts\/1995","targetHints":{"allow":["GET"]}}],"collection":[{"href":"http:\/\/jilin.hydesign.tw\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/jilin.hydesign.tw\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/jilin.hydesign.tw\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/jilin.hydesign.tw\/index.php\/wp-json\/wp\/v2\/comments?post=1995"}],"version-history":[{"count":68,"href":"http:\/\/jilin.hydesign.tw\/index.php\/wp-json\/wp\/v2\/posts\/1995\/revisions"}],"predecessor-version":[{"id":2098,"href":"http:\/\/jilin.hydesign.tw\/index.php\/wp-json\/wp\/v2\/posts\/1995\/revisions\/2098"}],"wp:attachment":[{"href":"http:\/\/jilin.hydesign.tw\/index.php\/wp-json\/wp\/v2\/media?parent=1995"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/jilin.hydesign.tw\/index.php\/wp-json\/wp\/v2\/categories?post=1995"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/jilin.hydesign.tw\/index.php\/wp-json\/wp\/v2\/tags?post=1995"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}