refactor(change_detect): Make ChangeDetectionUtil#uninitialized
a var
Previously, `uninitialized()` was a method, requiring a call as well as two extra characters everywhere it was used. Make this value a variable, saving the characters and avoiding the method call to get its value. This change also removes the export of `uninitialized` from change_detect.ts, which is technically a breaking change, however `uninitialized` is an implementation detail and nobody should be using it in app logic. By convention, apps should not be importing from files under `src/`. Update to #3248.
This commit is contained in:
@ -37,7 +37,7 @@ class _MyComponent_ChangeDetector0 extends _gen.AbstractChangeDetector {
|
||||
dynamic dispatcher, this._protos, this._directiveRecords)
|
||||
: super("MyComponent_comp_0", dispatcher) {
|
||||
_context = null;
|
||||
_myNum0 = _interpolate1 = _gen.ChangeDetectionUtil.uninitialized();
|
||||
_myNum0 = _interpolate1 = _gen.ChangeDetectionUtil.uninitialized;
|
||||
}
|
||||
|
||||
void detectChangesInRecords(throwOnChange) {
|
||||
@ -108,7 +108,7 @@ class _MyComponent_ChangeDetector0 extends _gen.AbstractChangeDetector {
|
||||
|
||||
void dehydrate() {
|
||||
_context = null;
|
||||
_myNum0 = _interpolate1 = _gen.ChangeDetectionUtil.uninitialized();
|
||||
_myNum0 = _interpolate1 = _gen.ChangeDetectionUtil.uninitialized;
|
||||
_locals = null;
|
||||
_pipes = null;
|
||||
}
|
||||
|
Reference in New Issue
Block a user