vue 開發環境搭建

1.創建vue項目

1.node js 生成項目,編譯項目

2.hbuilder 開發環境

1.下載安裝node js

http://nodejs.cn/download/

?

確認是否安裝成功

?

如果安裝不了 代碼錯誤2503

解決方法:

管理員命令運行cmd;

cd\

cd C:\Users\Administrator\Desktop

msiexec/package node-v6.3.1-x64.msi

(msi是版本號)

2.安裝 VUE CLI?

vue cli 是一個腳手架工具,用于生成一個基礎的vue應用。

npm install vue-cli -g

3.新建一個Vue項目

cd 目錄(你要把項目放在哪個目錄)

  • vue init webpack pname(你的項目名字)
  • ? Project description (A Vue.js project) vue-cli新建項目(項目描述)
  • ? Author (xhdx <zhuming3834@sina.com>) ;zhuming3834@sina.com(項目作者)
  • ? Vue build
    ? Runtime + Compiler: recommended for most users
    Runtime-only: about 6KB lighter min+gzip, but templates (or any Vue-specific HTML) are ONLY allowed in .vue files - render functions are required elsewhere
    這里選擇Runtime + Compiler: recommended for most users;

  • ? Install vue-router? (Y/n) y 是否使用vue-router,這里根據需求選擇;

  • ? Use ESLint to lint your code? (Y/n) y 是否使用ESLint,這里根據需求選擇;

  • ? Pick an ESLint preset (Use arrow keys)
    ? Standard (https://github.com/feross/standard)
    Airbnb (https://github.com/airbnb/javascript) none (configure it yourself) 這里選擇Standard (https://github.com/feross/standard)

  • ? Setup unit tests with Karma + Mocha? (Y/n) n 是否需要單元測試,這里根據需求選擇;

  • Setup e2e tests with Nightwatch? (Y/n) n是否需要單元測試,這里根據需求選擇;

  • cd pname(項目目錄);

  • npm install 安裝依賴

  • npm run dev 本地運行項目

?

?

?

?

?

?

?

?

?

?

?

?

?

默認瀏覽器會自動打開http://localhost:8080/#/,出現如下頁面:?
這里寫圖片描述
一共13步,一個vue-cli新建的模板項目就運行起來了。

轉載于:https://www.cnblogs.com/yubaibai/p/10457290.html

本文來自互聯網用戶投稿,該文觀點僅代表作者本人,不代表本站立場。本站僅提供信息存儲空間服務,不擁有所有權,不承擔相關法律責任。
如若轉載,請注明出處:http://www.pswp.cn/news/278252.shtml
繁體地址,請注明出處:http://hk.pswp.cn/news/278252.shtml
英文地址,請注明出處:http://en.pswp.cn/news/278252.shtml

如若內容造成侵權/違法違規/事實不符,請聯系多彩編程網進行投訴反饋email:809451989@qq.com,一經查實,立即刪除!

相關文章

iphone視圖放大_如何將iPhone用作放大鏡

iphone視圖放大It’s a common problem: Some things are just too hard to see. Usually, they’re too far away, too dark, or too small. With a feature called Magnifier, your iPhone can function as a magnifying glass and sight aid. Here’s how to use it. 這是一…

chmod權限

本文引用:https://www.cnblogs.com/zhangym/p/5826200.html linux數字權限解釋 644 第一位代表文件所有者的權限,第二位代表同組用戶的權限&#xff0c;第三位代表其他用戶的權限. 讀取權限等于4,用r表示;寫入權限2,用w表示;執行權限1,用x表示. 通過4、2、1組合,得到以下幾種權…

輸出最大值MXNet實現

網絡結構&#xff0c;輸入為2個數&#xff0c;先經過10個節點的全連接層&#xff0c;再經過10個節點的ReLu&#xff0c;再經過10個節點的全連接層&#xff0c;再經過1個節點的全連接層&#xff0c;最后輸出。 #-*-coding:utf-8-*- import logging import math import random im…

discord linux_如何在Discord中應用文本格式

discord linuxDiscord allows for text-and audio-based chatting between gamers and other like-minded individuals. If you want to make a bigger impact on Discord, you can use formatting to jazz up your text-based messages. Here’s how. Discord允許游戲玩家和其…

一張圖看懂阿里云網絡產品[十二]云企業網

2019獨角獸企業重金招聘Python工程師標準>>> 摘要&#xff1a; 阿里云致力于為用戶提供優質、高效、穩定的網絡傳輸環境&#xff0c;云企業網&#xff08;Cloud Enterprise Network&#xff09;將提供一種能夠快速構建混合云和分布式業務系統的全球網絡&#xff0c;…

# 2019-2020.3 《java程序設計》第一周學習總結

2019-2020-3 《Java 程序設計》第一周學習總結 在本周的學習中&#xff0c;學習到了好多也收獲了好多&#xff0c;從最基礎的安裝虛擬機開始&#xff0c;根據老師的博客中的教程一步一步的進行&#xff0c;在這過程中也遇到了好多問題&#xff0c;因為是初步接觸Linux系統&…

聊聊Java反射

反射是Java最重要的特性。通過Java反射可以在運行時知道一個類的所有成員和方法&#xff0c;知道一個對象的類類型、成員和方法的所有信息&#xff0c;進而調用對象的方法或生成對象的代理或包裝類。Java是面向對象語言&#xff0c;除了靜態變量或原始數據類型外都是完全面向對…

01. 把存儲過程結果集SELECT INTO到臨時表

原文:01. 把存儲過程結果集SELECT INTO到臨時表在開發過程中&#xff0c;很多時候要把結果集存放到臨時表中&#xff0c;常用的方法有兩種。 一. SELECT INTO 1. 使用select into會自動生成臨時表&#xff0c;不需要事先創建 select * into #temp from sysobjects select * fro…

day5學python 基礎+裝飾器內容

基礎裝飾器內容 遞歸特性# 1.必須有一個明確的結束條件# 2.每次進入更深一層遞歸時&#xff0c;問題規模相比上次遞歸應有所減少# 3.遞歸效率不高 def run(n):print(n)if int(n/2)>0:return run(n / 2)print("-->",n) run(10) 局部變量與全局變量知識 1.全局變…

如何在Windows 10上跳過回收站以刪除文件

Windows 10 normally sends files you delete to the Recycle Bin. They’ll be kept until you empty it—or, in some cases, until Windows 10 automatically empties your Recycle Bin. Here’s how to skip the Recycle Bin and delete files immediately. Windows 10通常…

OSChina 周日亂彈 —— 我叫張一條

2019獨角獸企業重金招聘Python工程師標準>>> Osc亂彈歌單&#xff08;2018&#xff09;請戳&#xff08;這里&#xff09; 【今日歌曲】 萊布妮子 &#xff1a;分享Lube的單曲《Skoro dembel》 《Skoro dembel》- Lube 手機黨少年們想聽歌&#xff0c;請使勁兒戳&am…

面向對象初識

一. 面向對象初識 1.1 回顧面向過程編程vs函數式編程 # 面向過程編程 測量對象的元素個個數。 s1 fjdsklafsjda count 0 for i in s1:count 1l1 [1,2,3,4] count 0 for i in l1:count 1 面向過程編程def func(s):count 0for i in s:count 1return count …

iOS逆向:在任意app上開啟malloc stack追蹤內存來源

lldb有一個內存調試工具malloc stack&#xff0c;開啟以后就可以查看某個內存地址的malloc和free記錄&#xff0c;追蹤對象是在哪里創建的。 這個工具可以打印出對象創建的堆棧&#xff0c;而在逆向時&#xff0c;也經常需要追蹤某些方法的調用棧&#xff0c;如果可以隨時打印出…

【CH4302】Interval GCD

思路&#xff1a;線段樹維護a的差分數組的gcd&#xff0c; 因為$gcd(a_1,a_2,a_3,...,a_n)gcd(a_1,a_2-a_1,a_3-a_2,...,a_n-a_{n-1})$。 原區間修改可以轉化為差分數組上的兩次單點修改。 因為實際計算時還需要原數&#xff0c;所以用樹狀數組維護b的增減量。 詢問時&#xff…

Vue 的路由實現 Hash模式 和 History模式

Hash 模式: Hash 模式的工作原理是onhashchange事件&#xff0c;Window對象可以監聽這個事件... 可以通過改變路徑的哈希值&#xff0c;來實現歷史記錄的保存&#xff0c;發生變化的hash 都會被瀏覽器給保存下來&#xff0c;所以下次盡管瀏覽器沒有請求服務器&#xff0c;但是還…

我的第一次——網站備案

暫無內容 轉載于:https://my.oschina.net/vright/blog/1784979

使用LiveClick升級您的實時書簽

If you like to subscribe to feeds using Firefox’s Live Bookmarks feature, the LiveClick extension gives you so many upgrades that I can only cover the highlights of how great it is. 如果您想使用Firefox的“實時書簽”功能訂閱供稿&#xff0c;則LiveClick擴展程…

操作系統的概論梳理

轉載于:https://www.cnblogs.com/hclhechunlu/p/10477470.html

win7下如何顯示緬文和使用緬文輸入法?

windows 7 操作系統默認不支持緬文&#xff0c;所以緬文在win7上不能顯示&#xff0c;當然也沒有提供緬文輸入法。 一、顯示緬文 windows系統下顯示緬文字母只需要安裝緬文字體就可以了。目前常見的緬文字體就是Zawgyi-One&#xff0c;Zawgyi-One是一種廣泛使用的緬文字體。Zaw…

airpods2使用_如何使用AirPods和AirPods Pro:完整指南

airpods2使用Burdun Iliya/ShutterstockBurdun Iliya /快門Just bought yourself or received a new pair of AirPods or AirPods Pro? Welcome to the truly wireless earphones life. Setting up AirPods is quite straightforward, but here’s how to customize and get t…