Hello,
I’ve decided in migrating to 2.0 to abandon my validator in favor of Aurelia’s, largely because of the state-based validation implementation, which I hadn’t implemented yet on my own validator.
But I need to be able to add a group property at the validation property level for presentational purposes (not to rules, which I know I can accomplish with tag, but to properties). Consider this code snippet from my Au 1.0 app, focusing on startGroup() and endGroup()in my fluent API:
_defineValidationRules() {
this.validationRules = new TsiValidator()
.virtualProperty('sufficientJobsites')
.virtualProperty('validJobsite', 'Invalid jobsite')
.property('templateId')
.required()
.done()
.startGroup('titling', 'project titling') // <-- Here
.property('name')
.required('Project name is required')
.size(3, 100)
.endGroup() // <-- And here
...
.done()
.startGroup('singleJobsite', 'jobsite') // <-- Here
.property('description')
.size(3, 50)
.property('streetAddress')
.callback((entity, value, args) => {
return !entity.PAS.isAmbiguous;
}, 'Address format must not be ambiguous')
...
.endGroup() // <-- And here
}
Every validation rule defined between startGroup and endGroup picks up a “group” meta property, which is both functional and presentational. Since you already provide the functional part through tagging, I’m focusing on the presentational part in this post.
The group property allows me to group the display of the validation errors in the validation panel at the right edge of the screen, which nicely corresponds to panels out in the source view:
Is this possible with Aurelia? I haven’t found such a scenario in the documentation.




