You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
What problem does this feature solve?
Sometimes traits need to be extended. For example, Validation Trait presets some rules, but the business logic always requires custom validation rules. Validation Trait needs to receive and register custom rules.
What does the proposed API look like?
Since the trait is a factory function, so one of the ways may be injecting dependencies in the trait's constructor function. And trait's dependencies can be passed in initSunmao(not the dependencies filed, but a new field).
The text was updated successfully, but these errors were encountered:
What problem does this feature solve?
Sometimes traits need to be extended. For example, Validation Trait presets some rules, but the business logic always requires custom validation rules. Validation Trait needs to receive and register custom rules.
What does the proposed API look like?
Since the trait is a factory function, so one of the ways may be injecting dependencies in the trait's constructor function. And trait's dependencies can be passed in
initSunmao
(not thedependencies
filed, but a new field).The text was updated successfully, but these errors were encountered: