-
-
Notifications
You must be signed in to change notification settings - Fork 350
[code-infra] Update AGENTS.md with error message instructions #3864
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Conversation
commit: |
Bundle size report
Check out the code infra dashboard for more information about this PR. |
✅ Deploy Preview for base-ui ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
|
|
||
| <!-- markdownlint-disable MD038 --> | ||
|
|
||
| - Prefix with `MUI: ` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| - Prefix with `MUI: ` | |
| - Prefix with `Base UI: ` |
|
|
||
| - Prefix with `MUI: ` | ||
| - Use string concatenation for readability | ||
| - Include a documentation link when applicable (`https://mui.com/r/...`) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| - Include a documentation link when applicable (`https://mui.com/r/...`) | |
| - Include a documentation link when applicable (`https://base-ui.com/...`) |
| ### Error Minifier | ||
|
|
||
| Use the `/* minify-error */` comment to activate the babel plugin: | ||
|
|
||
| ```tsx | ||
| throw /* minify-error */ new Error( | ||
| 'MUI: Expected valid input target. ' + | ||
| 'Did you use a custom `inputComponent` and forget to forward refs? ' + | ||
| 'See https://mui.com/r/input-component-ref-interface for more info.', | ||
| ); | ||
| ``` | ||
|
|
||
| The minifier works with both `Error` and `TypeError` constructors. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this relevant in this repo?
Seems like error messages are minified by default.
Port mui/material-ui#47668