Write to the front
I often see code records submitted by others that contain some features, fixes, chore, etc., but I don't distinguish anything when submitting, and just write down the submission information. Today, I'll take a look at what's going on, taking element-plus as an example.
In fact, writing this is a code submission specification. Of course, it is not to show off its skills. The main purpose is to improve the readability and automated processing capabilities of submission records.
Of course, if the team doesn't require it, it's okay not to write it this way.

git submission specifications
commit message = subject +:+ space + message body
** For example: ** Feature: : Added user registration function
Common types of subjects and their meanings are as follows:
- feat: New features
Used to submit new features.
Example: Feature: Add user registration function
- fix: fix bug
Used to submit bug fixes.
For example: fix: fix the login page crash problem
- docs: Document changes
Used to submit only document-related modifications.
For example: docs: Update the README file
- style: Code style change (does not affect code logic)
Used to submit only changes such as formatting, punctuation, and white space that do not affect the operation of the code.
For example: style: Delete unnecessary blank lines
- refactor: Code refactor (neither a new feature nor a code change to fix a bug)
Used to commit code refactoring.
Example: refactor: Refactor user verification logic
- perf: Performance optimization
Used to commit code modifications that improve performance.
For example: perf: Optimize image loading speed
- test: Add or modify a test
Used to submit test-related content.
For example: test: Add unit tests for user modules
- chore: Miscellaneous (changes to build process or assistive tools)
Used to submit content modifications related to the construction process, auxiliary tools, etc.
For example: chore: Update dependency libraries
- build: Changes to build systems or external dependencies
Used to commit changes that affect the build system.
Example: build: Upgrade webpack to version 5
- ci: Continuous integration configuration changes
Used to submit modifications to CI configuration files and scripts.
Example: ci: Modify the GitHub Actions configuration file
- ** reverse:** rollback
Used for committing before rolling back.
For example: reverse: rollback feature: Add user registration
summary
Using standardized commit messages makes the project more modular, easy to maintain, and understand, while also making it easier for automated tools such as publishing tools or Changelog generators to parse and process commit records.
By writing commit messages that meet specifications, teams and collaborators can better understand the project's change history and version control, thereby improving code maintenance efficiency and quality.