Skip to content

feat: enhance wechat-mini-program-development skill with best practices#13

Merged
MasamiYui merged 7 commits into
trae-community:mainfrom
gjwroot:feat/wechat-miniprogram-skill
Mar 9, 2026
Merged

feat: enhance wechat-mini-program-development skill with best practices#13
MasamiYui merged 7 commits into
trae-community:mainfrom
gjwroot:feat/wechat-miniprogram-skill

Conversation

@gjwroot

@gjwroot gjwroot commented Mar 7, 2026

Copy link
Copy Markdown
Contributor

Summary

This PR enhances the wechat-mini-program-development skill with additional best practices and utility functions based on real-world project experience.

Changes

  • Step 5: Added utils/util.js with common utility functions (formatTime, showLoading, showToast, showSuccess, showConfirm)
  • Step 6: Added global login status check in app.js with checkLoginStatus() method
  • Step 7: Added TabBar configuration example in app.json
  • Step 8: Enhanced usage examples with utility integration

Motivation

These additions make the skill more practical for real-world WeChat mini-program development by providing:

  1. Common utility functions that every mini-program needs
  2. Standard login flow implementation
  3. TabBar configuration template
  4. Better usage examples

Testing

  • All code examples are copy-pasteable
  • Follows WeChat mini-program best practices
  • Compatible with existing skill structure

Related

@MasamiYui

Copy link
Copy Markdown
Member

hi, please resolve conflicts

gjwroot added 7 commits March 8, 2026 13:26
- wx.redirectTo cannot navigate to tabBar pages
- wx.reLaunch can navigate to any page and clears page stack
- This fixes the issue where 401 redirect fails when login page is a tabBar page
Add new sections to improve developer experience:
- utils/util.js: Common utility functions (formatTime, showLoading, showToast, etc.)
- app.js: Global login status check with checkLoginStatus()
- app.json: TabBar configuration example
- Enhanced usage examples with util integration

All additions are generic and follow WeChat mini-program best practices,
making the skill more practical for real-world development.
@gjwroot
gjwroot force-pushed the feat/wechat-miniprogram-skill branch from ad17b7d to 8d2f29f Compare March 8, 2026 05:28
@gjwroot

gjwroot commented Mar 8, 2026

Copy link
Copy Markdown
Contributor Author

20260308141716_rec_

@MasamiYui MasamiYui left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm

@MasamiYui MasamiYui added documentation Improvements or additions to documentation enhancement New feature or request labels Mar 9, 2026
@MasamiYui
MasamiYui merged commit 6522b86 into trae-community:main Mar 9, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Improvements or additions to documentation enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants