-
Notifications
You must be signed in to change notification settings - Fork 775
Update "Feature guide" documentation #1595
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: main
Are you sure you want to change the base?
Conversation
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.
Pull request overview
This PR updates the Feature Guide documentation to align with recent changes in the main branch and creates a new dedicated Placeholder Pipes documentation page to better organize content.
Key changes:
- Adds comprehensive documentation for placeholder pipes with detailed examples of all available modifiers
- Restructures and expands the Feature Guide with new sections on validation methods, smart validation, PHP attributes, result composition, and advanced features
- Improves code examples and adds clearer explanations of validator behavior and immutability
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 2 comments.
| File | Description |
|---|---|
| docs/placeholder-pipes.md | New documentation file dedicated to explaining placeholder pipe modifiers with usage examples for raw, quote, trans, listOr, listAnd, and custom modifiers |
| docs/feature-guide.md | Major restructuring and expansion adding sections on validation methods, PHP attributes, result composition, prefixed shortcuts, custom templates for nested structures, naming validators, reusing validators, and advanced features like nested validation paths and helpful stack traces |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
|
|
||
| ## Custom Modifiers | ||
|
|
||
| You can create custom placeholder pipes by implementing your own stringifier logic when needed for specialized formatting requirements. |
Copilot
AI
Jan 8, 2026
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.
The section "Custom Modifiers" is vague and doesn't provide actionable information. It mentions "implementing your own stringifier logic" but doesn't explain how to do this, what interface to implement, or where to register custom modifiers. Consider either providing a concrete example or removing this section if custom modifiers aren't fully supported yet.
| You can create custom placeholder pipes by implementing your own stringifier logic when needed for specialized formatting requirements. | |
| At the moment, only the modifiers documented above are officially supported. Support for registering custom placeholder pipes is not part of the public API yet; when it becomes available, this section will be updated with concrete examples and configuration details. |
| ```php | ||
| $mysqlUserResult = $result->findByPath('mysql.user'); | ||
| if ($mysqlUserResult !== null) { | ||
| echo $mysqlUserResult; | ||
| } | ||
| ``` |
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.
This is missing some context. The last time we used the $result variable in this page was an int validation. Perhaps we need to introduce the database connection settings example more explicitly, or something smaller that can still be relevant for the path example.
|
|
||
| ### Prefixed shortcuts | ||
|
|
||
| For convenience, several prefixed shortcuts are available for validators that wrap other validators: |
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.
Perhaps we can link to the mixin class so the user can see all available shortcuts.
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.
That would be difficult, because there are multiple mixing classes. I think we could create a page with the prefixes, though. What do you think?
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.
That would be cool. They're generated aren't they? Perhaps we can generate the docs too.
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.
I just added a markdown with it. I haven't fully reviewed it though.
| ### Nested validation paths | ||
|
|
||
| Validation can trace the path of nested structures and display helpful messages: |
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.
There was a short introduction to paths before in this document, I left a comment about lacking context. Maybe we can remove it and replace for an anchor to this more in-depth part.
alganet
left a comment
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.
Some suggestions on terminology. Nothing critical.
4533d09 to
f8d9174
Compare
The documentation was quite outdated after the many changes I made in the main branch. This commit will make sure it's up-to-date. I'm also creating a "Placeholder pipes" documentation, so there's not too much content in the "Feature guide" Assisted-by: Zed (devstral-2:123b)
f8d9174 to
337a711
Compare
The documentation was quite outdated after the many changes I made in the main branch. This commit will make sure it's up-to-date.
I'm also creating a "Placeholder pipes" documentation, so there's not too much content in the "Feature guide"