angular/packages/forms/src/errors.ts
Andrew Kushnir 67df935b41 refactor(forms): use shared RuntimeError class (#44398)
This commit performs some refactoring of the AbstractControl-based classes to employ shared `RuntimeError` class and also updates the code to avoid duplication and improve minification.

PR Close #44398
2022-01-06 23:43:19 +00:00

22 lines
559 B
TypeScript

/**
* @license
* Copyright Google LLC All Rights Reserved.
*
* Use of this source code is governed by an MIT-style license that can be
* found in the LICENSE file at https://angular.io/license
*/
/**
* The list of error codes used in runtime code of the `forms` package.
* Reserved error code range: 1000-1999.
*/
export const enum RuntimeErrorCode {
// Reactive Forms errors (10xx)
// Basic structure validation errors
NO_CONTROLS = 1000,
MISSING_CONTROL = 1001,
MISSING_CONTROL_VALUE = 1002,
// Template-driven Forms errors (11xx)
}