From 84afe04b48c2e68b56030f5a2ab3902bcfc625dc Mon Sep 17 00:00:00 2001 From: duanledexianxianxian Date: Tue, 18 Jun 2019 17:55:06 +0800 Subject: [PATCH] test --- config/config.ts | 7 +++ public/iamges/todo1.png | Bin 0 -> 2298 bytes src/pages/demo/index.js | 19 ++++++++ src/pages/demo/index.less | 3 ++ "\347\216\257\345\242\203.md" | 80 ++++++++++++++++++++++++++++++++++ 5 files changed, 109 insertions(+) create mode 100644 public/iamges/todo1.png create mode 100644 src/pages/demo/index.js create mode 100644 src/pages/demo/index.less create mode 100644 "\347\216\257\345\242\203.md" diff --git a/config/config.ts b/config/config.ts index b7d2a6f0..179707c6 100644 --- a/config/config.ts +++ b/config/config.ts @@ -84,6 +84,7 @@ const uglifyJSOptions = } : {}; export default { + publicPath: "/test", // add for transfer to umi plugins, define: { @@ -109,6 +110,12 @@ export default { icon: 'smile', component: './Welcome', }, + { + path: '/demo', + name: 'demo', + icon: 'smile', + component: './demo', + }, ], }, ], diff --git a/public/iamges/todo1.png b/public/iamges/todo1.png new file mode 100644 index 0000000000000000000000000000000000000000..c6c8dbd6a1ec69e438c35e04686e11cc243cd8b1 GIT binary patch literal 2298 zcmV+w!m|0;SzX5fkxIF~)7J20?tFlBiJ>5{>au z1X7VjfB1+$6itjqjY=0JsEG0dBVd1^(fA0USQWdd0X0e#0>W+!C1~G|owQcTQNo+W+~r{Ehkr%f35`mP5i{$q(J4UuC5NVxUoYZ~s? zb@>v$`s6h7b6ibLib9Y7@Nn_F6zwjy+jC?9-}=zm)Fn2<2(xUrm;(lYuagDh?!C*r zN9>BXZGiH?v03=|wdm(Xb{oqnJ<)ME!Ghq5(mFfsD0Ya;YZ|JgE_Mt%@C*VUgmq&b z?O?Lx0SmWC^-wtcvJ~=BJHm&GmIS>vy`6k}IeK#rM+H|u+N(1mbFS?OE zl9nj%vY@}{r@khHm=!qT?b5rKV#&M&^1X@g2EB}>^qBGa(_;GxaSt#yGhA5D6Gi4E zgQ{CGB@|p)x~g!dcN)6KLU_fO@Cx4T8T<ETrsD>H>sPs<4I;1`)5+O&4MosB zwgvsA^YT^C4D83eh^1^pI{Mtz_hB`<0Po>NgbcdTAOLBqC^%=2f6`Ga^5*W8p0@ps z^QF-5#bWCgbddrpeA&`?1eNn1qu~L(ftjtq7(b>PH6pu~$DYmZ>=pI?;*WxU@4~{u zam5NL55S0@=6c|aVKzL#R}zXx?io{O=54vbp~m)-~0 z-YOKewtjh$qk(VkMmeUfIs7Q5kLO?vk7b3@5RyW7QbkSpXAj()qy4VgQ@NxHF_#M>q#UV4$i46k$!!Ck1M0@ac zkenbUB{r0cvVvpn`jsV5I+b1dR^!x2hqlToe=0u44lg8E&e>BnkXXl2oG;MeINXl3 zYp=pvPfwJYZJDuie0?%oL00(Tx)VrhJ1f>STxW$ok;a(zgmi7e7LyGRXyS145Bz+w z%3R)!uBPjs0npllJmvXstBa3wdzY_io+S0wn{*+s7X|c8;`TL%zpc&Tb-5U*pw9sh zCnO;v$|df8vf&9TD*RnNdUg5g(9akgRZVNXlvjKBA}8yYmQ>NQK9-K=a2aNd+IWqm zN_2(U@#icGjNQZ8SlEOZ{0mbrnypA|8_V9^yfI1Ac3EJBFWixur4*@utVcSJ@ULBu#Pg3T0-<|c1rIf2m<tY4u@^&jCu)ZtW3haGJ{LML#@M+a%a0p? zA2|0G<6{$-hw8%Ud`OdGQ*XrRvKrJB#n>mdp8+`Wm~(IYUJrf=z{}wJMY(91u_Y&0 z!{GfdC_oi~@NV4W^KgHPk@)+Q@{Pq&2WGreyF; zHNXH|$;(mLVF8NW{5-<1ZpMW^?126$+U1OtSJC{eU@W;&Z1fU~VR>ly|23F3%x)c$QQW(2;E+CNSv8iC8B_OG+ahT!K>`RD0WhTyv4{`dL+0GCOq UgkaLX*#H0l07*qoM6N<$f{XuULI3~& literal 0 HcmV?d00001 diff --git a/src/pages/demo/index.js b/src/pages/demo/index.js new file mode 100644 index 00000000..664da9af --- /dev/null +++ b/src/pages/demo/index.js @@ -0,0 +1,19 @@ +import React from 'react'; +import { connect } from 'dva'; +// import styles from './index.less'; + +@connect() +class Index extends React.Component { + componentDidMount() {} + + render() { + return ( +
+ hello world + demo +
+ ); + } +} + +export default Index; diff --git a/src/pages/demo/index.less b/src/pages/demo/index.less new file mode 100644 index 00000000..9e118057 --- /dev/null +++ b/src/pages/demo/index.less @@ -0,0 +1,3 @@ +.root { + margin-bottom: 0; +} diff --git "a/\347\216\257\345\242\203.md" "b/\347\216\257\345\242\203.md" new file mode 100644 index 00000000..fc69a65f --- /dev/null +++ "b/\347\216\257\345\242\203.md" @@ -0,0 +1,80 @@ +### 安装node + +### npm配置 + +设置npm全局与缓存路径 + +``` +npm config set prefix "F:\NODEJS\node_global" + +npm config set cache "F:\NODEJS\node_cache" +``` + +查看npm配置 + +``` +npm config list +``` + +设置npm镜像源 + +``` +npm config set registry https://registry.npm.taobao.org --global +npm config set disturl https://npm.taobao.org/dist --global +``` + +### 安装yarn + +### 安装yrm + +切换仓库数据源 + +### 屏幕分辨率支持 + +1. 最低分辨率1366*768 +2. 最佳分辨率 1920*1080 + +### package.json + +``` +private +如果你在包的package.json中设置"private": true,则npm会拒绝发布它。 +``` + +### lint + +1. 远程lint + +2. 本地lint + + 1. [husky](https://github.com/typicode/husky) + + `husky` 其实就是一个为 `git` 客户端增加 hook 的工具 + + 2. [pre-commit](https://github.com/observing/pre-commit) + + 3. [lint-staged](https://github.com/okonet/lint-staged) 每次提交只检查本次提交所修改的文件 + + + + + + + +### 专业名词 + +| 英文缩写 | 英文全称 | 中文含义 | +| -------- | -------- | -------- | +| CI | | 持续集成 | +| | | | +| | | | + + + + + + + +### 参考链接 + +1. lint \ No newline at end of file -- GitLab