From ff30321c35c31e5968a41e839bca60b6e4db7b4a Mon Sep 17 00:00:00 2001 From: YM <479443481@qq.com> Date: 星期一, 25 三月 2024 17:38:31 +0800 Subject: [PATCH] 项目基础文件优化 --- utils/util.js | 4 - package.json | 5 - README.md | 132 -------------------------------------------- 3 files changed, 2 insertions(+), 139 deletions(-) diff --git a/README.md b/README.md index 5b9af5c..e69de29 100644 --- a/README.md +++ b/README.md @@ -1,132 +0,0 @@ -<p align="center"> - <a href="https://tdesign.tencent.com/" target="_blank"> - <img alt="TDesign Logo" width="200" src="https://tdesign.gtimg.com/site/TDesign.png"> - </a> -</p> - -<p align="center"> - <a href="https://img.shields.io/github/stars/Tencent/tdesign-miniprogram-starter-retail"> - <img src="https://img.shields.io/github/stars/Tencent/tdesign-miniprogram-starter-retail" alt="License"> - </a> - <a href="https://github.com/Tencent/tdesign-miniprogram-starter-retail/issues"> - <img src="https://img.shields.io/github/issues/Tencent/tdesign-miniprogram-starter-retail" alt="License"> - </a> - <a href="https://github.com/Tencent/tdesign-miniprogram-starter-retail/LICENSE"> - <img src="https://img.shields.io/github/license/Tencent/tdesign-miniprogram-starter-retail" alt="License"> - </a> - <a href="https://www.npmjs.com/package/tdesign-miniprogram"> - <img src="https://img.shields.io/npm/v/tdesign-miniprogram.svg?sanitize=true" alt="Version"> - </a> - <a href="https://www.npmjs.com/package/tdesign-miniprogram"> - <img src="https://img.shields.io/npm/dw/tdesign-miniprogram" alt="Downloads"> - </a> -</p> - -# TDesign 闆跺敭琛屼笟妯$増绀轰緥灏忕▼搴� - -TDesign 闆跺敭妯$増绀轰緥灏忕▼搴忛噰鐢� [TDesign 浼佷笟绾ц璁′綋绯诲皬绋嬪簭瑙e喅鏂规](https://tdesign.tencent.com/miniprogram/overview) 杩涜鎼缓锛屼緷璧� [TDesign 寰俊灏忕▼搴忕粍浠跺簱](https://github.com/Tencent/tdesign-miniprogram)锛屾兜鐩栧畬鏁寸殑鍩烘湰闆跺敭鍦烘櫙闇�姹傘�� - -## :high_brightness: 棰勮 - -<p>璇蜂娇鐢ㄥ井淇℃壂鎻忎互涓嬩簩缁寸爜锛�</p> - - <img src="https://we-retail-static-1300977798.cos.ap-guangzhou.myqcloud.com/retail-mp/common/qrcode.jpeg" width = "200" height = "200" alt="妯$増灏忕▼搴忎簩缁寸爜" align=center /> - -## :pushpin: 椤圭洰浠嬬粛 - -### 1. 涓氬姟浠嬬粛 - -闆跺敭琛屼笟妯$増灏忕▼搴忔槸涓粡鍏哥殑鍗曞簵鐗堢數鍟嗗皬绋嬪簭锛屾兜鐩栦簡鐢靛晢鐨勯粍閲戦摼璺祦绋嬶紝浠庡晢鍝�->璐墿杞�->缁撶畻->璁㈠崟绛夈�傚皬绋嬪簭鎬诲叡鍖呭惈 28 涓畬鏁寸殑椤甸潰锛屾兜鐩栭椤碉紝鍟嗗搧璇︽儏椤碉紝涓汉涓績锛屽敭鍚庢祦绋嬬瓑鍩虹椤甸潰銆傞噰鐢� mock 鏁版嵁杩涜灞曠ず锛屾彁渚涗簡瀹屾暣鐨勯浂鍞晢鍝佸睍绀恒�佷氦鏄撲笌鍞悗娴佺▼銆傞〉闈㈣鎯咃細 - -<img src="https://cdn-we-retail.ym.tencent.com/tsr/tdesign-starter-readmeV1.png" width = "650" height = "900" alt="妯$増灏忕▼搴忛〉闈㈣鎯�" align=center /> - - - -涓昏椤甸潰鎴浘濡備笅锛� - -<p align="center"> - <img alt="example-home" width="200" src="https://cdn-we-retail.ym.tencent.com/tsr/example/v1/home.png" /> - <img alt="example-sort" width="200" src="https://cdn-we-retail.ym.tencent.com/tsr/example/v2/sort.png" /> - <img alt="example-cart" width="200" src="https://cdn-we-retail.ym.tencent.com/tsr/example/v1/cart.png" /> - <img alt="example-user-center" width="200" src="https://cdn-we-retail.ym.tencent.com/tsr/example/v1/user-center.png" /> - <img alt="example-goods-detail" width="200" src="https://cdn-we-retail.ym.tencent.com/tsr/example/v1/goods-detail.png" /> - <img alt="example-pay" width="200" src="https://cdn-we-retail.ym.tencent.com/tsr/example/v1/pay.png" /> - <img alt="example-order" width="200" src="https://cdn-we-retail.ym.tencent.com/tsr/example/v1/order.png" /> - <img alt="example-order-detail" width="200" src="https://cdn-we-retail.ym.tencent.com/tsr/example/v2/order.png" /> -</p> - - - -### 2. 椤圭洰鏋勬垚 - -闆跺敭琛屼笟妯$増灏忕▼搴忛噰鐢ㄥ熀纭�鐨� JavaScript + WXSS + ESLint 杩涜鏋勫缓锛岄檷浣庝簡浣跨敤闂ㄦ銆� - -椤圭洰鐩綍缁撴瀯濡備笅锛� - -``` -|-- tdesign-miniprogram-starter - |-- README.md - |-- app.js - |-- app.json - |-- app.wxss - |-- components // 鍏叡缁勪欢搴� - |-- config // 鍩虹閰嶇疆 - |-- custom-tab-bar // 鑷畾涔� tabbar - |-- model // mock 鏁版嵁 - |-- pages - | |-- cart // 璐墿杞︾浉鍏抽〉闈� - | |-- coupon // 浼樻儬鍒哥浉鍏抽〉闈� - | |-- goods // 鍟嗗搧鐩稿叧椤甸潰 - | |-- home // 棣栭〉 - | |-- order // 璁㈠崟鍞悗鐩稿叧椤甸潰 - | |-- promotion-detail // 钀ラ攢娲诲姩椤甸潰 - | |-- usercenter // 涓汉涓績鍙婃敹璐у湴鍧�鐩稿叧椤甸潰 - |-- services // 璇锋眰鎺ュ彛 - |-- style // 鍏叡鏍峰紡涓巌confont - |-- utils // 宸ュ叿搴� -``` - -### 3. 鏁版嵁妯℃嫙 - -闆跺敭灏忕▼搴忛噰鐢ㄧ湡瀹炵殑鎺ュ彛鏁版嵁锛屾ā鎷熷悗绔繑鍥為�昏緫锛屽湪灏忕▼搴忓睍绀哄畬鏁寸殑璐墿鍦烘櫙涓庤喘鐗╀綋楠岄�昏緫銆� - -### 4. 娣诲姞鏂伴〉闈� - -1. 鍦� `pages `鐩綍涓嬪垱寤哄搴旂殑椤甸潰鏂囦欢澶� -2. 鍦� `app.json` 鏂囦欢涓殑 ` "pages"` 鏁扮粍涓姞涓婇〉闈㈣矾寰� -3. [鍙�塢 鍦� `project.config.json` 鏂囦欢鐨� `"miniprogram-list"` 涓嬫坊鍔犻〉闈㈤厤缃� - -## :hammer: 鏋勫缓杩愯 - -1. `npm install` -2. 灏忕▼搴忓紑鍙戝伐鍏蜂腑寮曞叆宸ョ▼ -3. 鏋勫缓 npm - -## :art: 浠g爜椋庢牸鎺у埗 - -`eslint` `prettier` - -## :iphone: 鍩虹搴撶増鏈� - -鏈�浣庡熀纭�搴撶増鏈琡^2.6.5` - -## :dart: 鍙嶉 - -浼佷笟寰俊缇� -TDesign 鍥㈤槦浼氬強鏃跺湪浼佷笟寰俊澶х兢涓悓姝ュ彂甯冪増鏈�侀棶棰樹慨澶嶄俊鎭紝涔熶細鏈変竴浜涘叧浜庣粍浠跺簱寤鸿鐨勮璁猴紝娆㈣繋寰俊鎴栦紒涓氬井淇℃壂鐮佸叆缇や氦娴侊細 - -<img src="https://oteam-tdesign-1258344706.cos.ap-guangzhou.myqcloud.com/site/doc/TDesign%20IM.png" width = "200" height = "200" alt="妯$増灏忕▼搴忛〉闈㈣鎯�" align=center /> - - -閭欢鑱旂郴锛歵design@tencent.com - -## :link: TDesign 鍏朵粬鎶�鏈爤瀹炵幇 - -- 绉诲姩绔� 灏忕▼搴� 瀹炵幇锛歔mobile-miniprogram](https://github.com/Tencent/tdesign-miniprogram) -- 妗岄潰绔� Vue 2 瀹炵幇锛歔web-vue](https://github.com/Tencent/tdesign-vue) -- 妗岄潰绔� Vue 3 瀹炵幇锛歔web-vue-next](https://github.com/Tencent/tdesign-vue-next) -- 妗岄潰绔� React 瀹炵幇锛歔web-react](https://github.com/Tencent/tdesign-react) - -## :page_with_curl: 寮�婧愬崗璁� - -TDesign 閬靛惊 [MIT 鍗忚](https://github.com/Tencent/tdesign-miniprogram-starter-retail/LICENSE)銆� diff --git a/package.json b/package.json index 165c529..5309c96 100644 --- a/package.json +++ b/package.json @@ -1,5 +1,5 @@ { - "name": "@tencent/tdesign-miniprogram-starter-retail", + "name": "jsek-applet", "version": "1.0.0", "description": "", "main": "app.js", @@ -24,7 +24,6 @@ ] }, "dependencies": { - "dayjs": "^1.9.3", "moment": "^2.30.1", "spark-md5": "^3.0.2", "tdesign-miniprogram": "^1.0.0", @@ -44,4 +43,4 @@ "lint-staged": "^10.0.8", "prettier": "^2.1.2" } -} +} \ No newline at end of file diff --git a/utils/util.js b/utils/util.js index 4f0ec66..ab0d7fe 100644 --- a/utils/util.js +++ b/utils/util.js @@ -1,6 +1,3 @@ -import dayjs from 'dayjs'; - -const formatTime = (date, template) => dayjs(date).format(template); /** * 鏍煎紡鍖栦环鏍兼暟棰濅负瀛楃涓� @@ -123,7 +120,6 @@ }; module.exports = { - formatTime, priceFormat, cosThumb, get, -- Gitblit v1.9.1