{"id":13603941,"url":"https://github.com/wsdo/taro-kit","last_synced_at":"2025-04-11T22:32:03.232Z","repository":{"id":37677938,"uuid":"150226422","full_name":"wsdo/taro-kit","owner":"wsdo","description":"🏆✌️taro 小程序脚手架。 特性： 封装api、redux优雅集成、生成海报类，异常日志上报。 如果能帮到你，就给个 star😊","archived":false,"fork":false,"pushed_at":"2021-11-30T11:21:48.000Z","size":371,"stargazers_count":704,"open_issues_count":8,"forks_count":112,"subscribers_count":84,"default_branch":"master","last_synced_at":"2025-04-10T04:02:41.112Z","etag":null,"topics":["react","redux","taro","taro-kit","xiaochengxu"],"latest_commit_sha":null,"homepage":"https://shudong.wang","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/wsdo.png","metadata":{"files":{"readme":"readme.md","changelog":"changelog.md","contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2018-09-25T07:43:11.000Z","updated_at":"2025-04-02T00:37:42.000Z","dependencies_parsed_at":"2022-09-06T16:00:36.149Z","dependency_job_id":null,"html_url":"https://github.com/wsdo/taro-kit","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wsdo%2Ftaro-kit","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wsdo%2Ftaro-kit/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wsdo%2Ftaro-kit/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wsdo%2Ftaro-kit/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/wsdo","download_url":"https://codeload.github.com/wsdo/taro-kit/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248489759,"owners_count":21112633,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["react","redux","taro","taro-kit","xiaochengxu"],"created_at":"2024-08-01T19:00:36.900Z","updated_at":"2025-04-11T22:32:02.811Z","avatar_url":"https://github.com/wsdo.png","language":"TypeScript","funding_links":[],"categories":["示例项目","TypeScript"],"sub_categories":["Taro 2"],"readme":"\u003c!--\n * @Author: starkwang\n * @Contact me: https://shudong.wang/about\n * @Date: 2019-09-16 13:55:47\n * @LastEditors: starkwang\n * @LastEditTime: 2019-10-24 15:37:26\n * @Description: file content\n --\u003e\n\n## 可以 watch 这个项目，有更新，及时知道\n\n\u003e 项目会不断迭代，有需求欢迎 issue 如果能帮到你，那就给个 star 呗！\n\n\u003e 1 年前输出了一套 taro-kit 脚手架，有不少人加我微信，咨询一些问题，这段时间把这个脚手架升级后，总结并录制了课程，希望能帮助到大家，提高效率，节约时间。\n\nCLI 工具安装首先，你需要使用 npm 或者 yarn 全局安装@tarojs/cli，或者直接使用 npx:\n\n```js\n# 使用 npm 安装 CLI\n$ npm install -g @tarojs/cli\n# OR 使用 yarn 安装 CLI\n$ yarn global add @tarojs/cli\n# OR 安装了 cnpm，使用 cnpm 安装 CLI\n$ cnpm install -g @tarojs/cli\n```\n\n## 项目更新：\n\n\u003e 2021年11月30日\n\n- 更新@tarojs/taro到：3.3.15\n\n- 添加海报生成插件：[taro-weapp-poster](https://github.com/Clycheng/taro-weapp-poster)\n\n\n\u003e 2021 年 02 月 03 日 星期三\n\n- 更新依赖到：3.0.26\n- 更新.eslintrc\n- 添加 babel 配置\n- 添加 global.d.ts\n- 添加 tsconfig\n- 添加 yarn.lock 文件\n- 更新 config 文件\n\n\n```\ntaro update project v版本号\n```\n\n\u003e ![20210122111946](http://s.shudong.wang/note/20210122111946.png)\n\n## 文章\n\n- [【小程序 taro 最佳实践】http 请求封装（方便使用，增加 token，统一错误日志记录和上报）](https://segmentfault.com/a/1190000016533592)\n- [【小程序 taro 最佳实践】异步 action 优雅实践(简化流程)](https://segmentfault.com/a/1190000016534001)\n- [【taro 最佳实践】设置好基础开发字体尺寸](https://segmentfault.com/a/1190000016514478)\n\n- [Taro 小程序，从 0 到 1 架构项目，打造自己的完美脚手架。 ](https://segmentfault.com/a/1190000019020009)\n\n## 功能列表\n\n- [x] 封装 api 请求方式\n- [x] 更方便的创建 action：增加 createApiAction\n- [x] 基础像素试着为 1 倍即：1px 会编译成 2rpx（小程序默认是 2 倍）符合习惯\n- [x] 基础 demo 案列\n- [x] 增加生成海报类\n\n## 升级功能列表\n\n- [x] 01.taro 从 0 到 1 项目架构课程介绍\n- [x] 02.初始化项目流程介绍、目录设计\n- [x] 03.让 alias 别名解决路径引用的烦恼\n- [x] 04.请求 api 返回 redux 的状态流程\n- [x] 05.封装 request get 请求，给 url 添加时间戳防止浏览器缓存\n- [x] 06.封装 request post Content-Type 分类请求\n- [x] 07.把 taro-advance 脚手架推送到私有仓库\n- [x] 08.弱网请求失败时自动发起 api 重试\n- [x] 09.异常日志上报封装设计思路\n- [x] 10.异常日志上报封装，五种级别输出。\n- [x] 11.上报收集日志平台系统介绍\n- [x] 12.实战接入日志平台\n- [x] 13.深度序列化错误 error 控制台上报\n- [x] 14.登录流程讲解（前端和后端实现流程）\n- [x] 15.登录实现详细讲解（token 附加到请求 header 头）\n- [x] 16.用户授权后更新用户信息流程\n- [x] 17.设计 createApiAction 自动 dispatch 优化开发体验\n- [x] 18.改造 actionType 支持庞大业务\n- [x] 19.Action 三种 ActionType 的集合\n- [x] 20.简化 reducers 的 swich 繁琐操作\n- [x] 21.增加 request 的状态\n- [x] 22.课程总结\n- [x] 23.添加 Prettier 格式化配置\n\n\u003e 这个可以让你的 Taro 小程序跑的更优雅一些\n\n#### 升级后的项目仓库地址： 观看视频的同学加微信，发送你的 gitlab 账号，添加权限，你就看源代码了。\n\nhttps://gitlab.com/itxishu/taro-advance.git\n\n## 观看地址：segmentfault\n\n#### 购买路径\n在 https://shudong.wang 加我微信\n\nhttps://segmentfault.com/ls/1650000018991514\n\n## 适宜人群\n\n- taro 小程序开发者\n- 需要 taro 基础架构开发人员\n\n## 课程说明\n\n本次课程主要针对于，正在使用 taro 小程序框架的同学，通过课程，你可以学到，框架的 request 请求优雅封装，异常自动重试，日志异常上报， redux 的三剑客优雅的配合使用， reducer 的 swich 简化繁琐操作，增加 state 的请求前，请求成功和失败的状态等。从开始架构足以支撑庞大业务小程序项目\n\n课程有问题可以在 https://shudong.wang 我的博客扎到我，添加微信咨询\n\n![2019-04-28-22-09-17](http://s.shudong.wang/2019-04-28-22-09-17.png)\n\n#### 有问题加微信问吧\n\nhttps://www.shudong.wang/about\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwsdo%2Ftaro-kit","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fwsdo%2Ftaro-kit","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwsdo%2Ftaro-kit/lists"}