set()
Sets the `ValidationError` object under the given `id`
ValidationErrors.prototype.set()
public set<ErrorId extends Id>(
problem: string,
fix: string,
id: ErrorId,
template = ValidationErrors.template
): this {
this.isAllowedId(id) &&
this.errors.set(id, new ValidationError(problem, fix, id, template));
return this;
}Generic type variables
ErrorIdextendsId
Parameters
problem:string
fix:string
id:ErrorId
template =ValidationErrors.template
Return type
this
Example usage
Last updated