近期接觸了下前端項目,記錄下學習過程。css
近幾年前端發展的迅猛,各類框架層出不窮,vue react angular ,各類第三方組件html
原來會點js,jQuery 先後端一我的全搞定了,如今先後端分離,後端主要提供接口,前端主要負責交互前端
對於我的來講會更專一本身的業務,固然對於企業來講會多了一我的力成本。vue
通常都使用VSCode ,下載地址 https://code.visualstudio.com/ 很是簡潔,能夠靈活安裝一些插件。node
下載地址:http://nodejs.cn/download/react
安裝步驟很簡單,只要一路「next」就能夠了。git
安裝完成後,打開命令行工具輸入命令node -v,以下圖,若是出現對應版本號,就說明安裝成功了。npm
npm包管理器,是集成在node中的,因此,直接輸入npm -v就會以下圖所示,顯示出npm的版本信息element-ui
聽同事介紹說yarn比npm 快不少,也比較穩定,因此直接安裝yarn json
進入終端用npm安裝yarn
npm install -g yarn
切換淘寶鏡像(能夠切換本公司的鏡像)
yarn config set registry https://registry.npm.taobao.org
下載項目,並啓動
//下載項目 git clone git@xxxx //安裝依賴 yarn // 啓動項目 yarn serve
初始化 yarn init npm init 安裝依賴 yarn install 或者 yarn npm install pnpm install 新增依賴 yarn add element-ui npm install element-ui --save pnpm i element-ui 刪除依賴 yarn remove element-ui npm uninstall element-ui --save … 更新依賴 yarn upgrade npm update pnpm update
更多命令查看:https://yarn.bootcss.com/
這樣環境基本就搭建好了。
後面有時間再說說語法。
沒接觸以前感受不會用,未知領域老是以爲好厲害好高深的樣子,環境搭建好,瞭解下基本語法基本就能上手項目了。
先邁出第一步。
相關連接: