Socket
Socket
Sign inDemoInstall

@angular/forms

Package Overview
Dependencies
2
Maintainers
1
Versions
802
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 2.1.1 to 2.1.2

6

package.json
{
"name": "@angular/forms",
"version": "2.1.1",
"version": "2.1.2",
"description": "Angular - directives and services for creating forms",

@@ -11,4 +11,4 @@ "main": "bundles/forms.umd.js",

"peerDependencies": {
"@angular/core": "2.1.1",
"@angular/common": "2.1.1"
"@angular/core": "2.1.2",
"@angular/common": "2.1.2"
},

@@ -15,0 +15,0 @@ "repository": {

@@ -15,3 +15,2 @@ /**

import { EventEmitter } from '../facade/async';
import { ListWrapper } from '../facade/collection';
import { isPresent } from '../facade/lang';

@@ -153,3 +152,3 @@ import { FormGroup } from '../model';

path.pop();
return ListWrapper.isEmpty(path) ? this.form : this.form.get(path);
return path.length ? this.form.get(path) : this.form;
};

@@ -156,0 +155,0 @@ NgForm.decorators = [

@@ -9,3 +9,2 @@ /**

import { Directive, ElementRef, Injectable, Injector, Input, Renderer, forwardRef } from '@angular/core';
import { ListWrapper } from '../facade/collection';
import { NG_VALUE_ACCESSOR } from './control_value_accessor';

@@ -35,3 +34,3 @@ import { NgControl } from './ng_control';

}
ListWrapper.removeAt(this._accessors, indexToRemove);
this._accessors.splice(indexToRemove, 1);
};

@@ -38,0 +37,0 @@ RadioControlRegistry.prototype.select = function (accessor) {

@@ -33,28 +33,7 @@ export declare class MapWrapper {

export declare class ListWrapper {
static createFixedSize(size: number): any[];
static createGrowableSize(size: number): any[];
static clone<T>(array: T[]): T[];
static forEachWithIndex<T>(array: T[], fn: (t: T, n: number) => void): void;
static first<T>(array: T[]): T;
static last<T>(array: T[]): T;
static indexOf<T>(array: T[], value: T, startIndex?: number): number;
static contains<T>(list: T[], el: T): boolean;
static reversed<T>(array: T[]): T[];
static concat(a: any[], b: any[]): any[];
static insert<T>(list: T[], index: number, value: T): void;
static removeAt<T>(list: T[], index: number): T;
static removeAll<T>(list: T[], items: T[]): void;
static remove<T>(list: T[], el: T): boolean;
static clear(list: any[]): void;
static isEmpty(list: any[]): boolean;
static fill(list: any[], value: any, start?: number, end?: number): void;
static equals(a: any[], b: any[]): boolean;
static slice<T>(l: T[], from?: number, to?: number): T[];
static splice<T>(l: T[], from: number, length: number): T[];
static sort<T>(l: T[], compareFn?: (a: T, b: T) => number): void;
static toString<T>(l: T[]): string;
static toJSON<T>(l: T[]): string;
static maximum<T>(list: T[], predicate: (t: T) => number): T;
static flatten<T>(list: Array<T | T[]>): T[];
static addAll<T>(list: Array<T>, source: Array<T>): void;
}

@@ -61,0 +40,0 @@ export declare function isListLikeIterable(obj: any): boolean;

@@ -8,3 +8,3 @@ /**

*/
import { getSymbolIterator, isBlank, isJsObject, isPresent } from './lang';
import { getSymbolIterator, isJsObject, isPresent } from './lang';
// Safari doesn't implement MapIterator.next(), which is used is Traceur's polyfill of Array.from

@@ -82,38 +82,2 @@ // TODO(mlaval): remove the work around once we have a working polyfill of Array.from

}
// JS has no way to express a statically fixed size list, but dart does so we
// keep both methods.
ListWrapper.createFixedSize = function (size) { return new Array(size); };
ListWrapper.createGrowableSize = function (size) { return new Array(size); };
ListWrapper.clone = function (array) { return array.slice(0); };
ListWrapper.forEachWithIndex = function (array, fn) {
for (var i = 0; i < array.length; i++) {
fn(array[i], i);
}
};
ListWrapper.first = function (array) {
if (!array)
return null;
return array[0];
};
ListWrapper.last = function (array) {
if (!array || array.length == 0)
return null;
return array[array.length - 1];
};
ListWrapper.indexOf = function (array, value, startIndex) {
if (startIndex === void 0) { startIndex = 0; }
return array.indexOf(value, startIndex);
};
ListWrapper.contains = function (list, el) { return list.indexOf(el) !== -1; };
ListWrapper.reversed = function (array) {
var a = ListWrapper.clone(array);
return a.reverse();
};
ListWrapper.concat = function (a, b) { return a.concat(b); };
ListWrapper.insert = function (list, index, value) { list.splice(index, 0, value); };
ListWrapper.removeAt = function (list, index) {
var res = list[index];
list.splice(index, 1);
return res;
};
ListWrapper.removeAll = function (list, items) {

@@ -133,9 +97,2 @@ for (var i = 0; i < items.length; ++i) {

};
ListWrapper.clear = function (list) { list.length = 0; };
ListWrapper.isEmpty = function (list) { return list.length == 0; };
ListWrapper.fill = function (list, value, start, end) {
if (start === void 0) { start = 0; }
if (end === void 0) { end = null; }
list.fill(value, start, end === null ? list.length : end);
};
ListWrapper.equals = function (a, b) {

@@ -150,18 +107,2 @@ if (a.length != b.length)

};
ListWrapper.slice = function (l, from, to) {
if (from === void 0) { from = 0; }
if (to === void 0) { to = null; }
return l.slice(from, to === null ? undefined : to);
};
ListWrapper.splice = function (l, from, length) { return l.splice(from, length); };
ListWrapper.sort = function (l, compareFn) {
if (isPresent(compareFn)) {
l.sort(compareFn);
}
else {
l.sort();
}
};
ListWrapper.toString = function (l) { return l.toString(); };
ListWrapper.toJSON = function (l) { return JSON.stringify(l); };
ListWrapper.maximum = function (list, predicate) {

@@ -175,3 +116,3 @@ if (list.length == 0) {

var candidate = list[index];
if (isBlank(candidate)) {
if (candidate == null) {
continue;

@@ -192,7 +133,2 @@ }

};
ListWrapper.addAll = function (list, source) {
for (var i = 0; i < source.length; i++) {
list.push(source[i]);
}
};
return ListWrapper;

@@ -199,0 +135,0 @@ }());

@@ -31,3 +31,3 @@

export declare function scheduleMicroTask(fn: Function): void;
declare var _global: BrowserNodeGlobal;
declare const _global: BrowserNodeGlobal;
export { _global as global };

@@ -39,3 +39,2 @@ export declare function getTypeNameForDebugging(type: any): string;

export declare function isDate(obj: any): obj is Date;
export declare function noop(): void;
export declare function stringify(token: any): string;

@@ -48,4 +47,2 @@ export declare class NumberWrapper {

export declare function looseIdentical(a: any, b: any): boolean;
export declare function normalizeBlank(obj: Object): any;
export declare function normalizeBool(obj: boolean): boolean;
export declare function isJsObject(o: any): boolean;

@@ -52,0 +49,0 @@ export declare function print(obj: Error | Object): void;

@@ -38,6 +38,6 @@ /**

export function isPresent(obj) {
return obj !== undefined && obj !== null;
return obj != null;
}
export function isBlank(obj) {
return obj === undefined || obj === null;
return obj == null;
}

@@ -51,3 +51,2 @@ var STRING_MAP_PROTO = Object.getPrototypeOf({});

}
export function noop() { }
export function stringify(token) {

@@ -106,8 +105,2 @@ if (typeof token === 'string') {

}
export function normalizeBlank(obj) {
return isBlank(obj) ? null : obj;
}
export function normalizeBool(obj) {
return isBlank(obj) ? false : obj;
}
export function isJsObject(o) {

@@ -141,4 +134,4 @@ return o !== null && (typeof o === 'function' || typeof o === 'object');

export function getSymbolIterator() {
if (isBlank(_symbolIterator)) {
if (isPresent(globalScope.Symbol) && isPresent(Symbol.iterator)) {
if (!_symbolIterator) {
if (globalScope.Symbol && Symbol.iterator) {
_symbolIterator = Symbol.iterator;

@@ -145,0 +138,0 @@ }

@@ -1,1 +0,1 @@

{"__symbolic":"module","version":1,"metadata":{"getTypeNameForDebugging":{"__symbolic":"function","parameters":["type"],"value":{"__symbolic":"binop","operator":"||","left":{"__symbolic":"index","expression":{"__symbolic":"reference","name":"type"},"index":"name"},"right":{"__symbolic":"error","message":"Expression form not supported","line":61,"character":25}}},"isPresent":{"__symbolic":"function","parameters":["obj"],"value":{"__symbolic":"binop","operator":"&&","left":{"__symbolic":"binop","operator":"!==","left":{"__symbolic":"reference","name":"obj"},"right":{"__symbolic":"reference","name":"undefined"}},"right":{"__symbolic":"binop","operator":"!==","left":{"__symbolic":"reference","name":"obj"},"right":null}}},"isBlank":{"__symbolic":"function","parameters":["obj"],"value":{"__symbolic":"binop","operator":"||","left":{"__symbolic":"binop","operator":"===","left":{"__symbolic":"reference","name":"obj"},"right":{"__symbolic":"reference","name":"undefined"}},"right":{"__symbolic":"binop","operator":"===","left":{"__symbolic":"reference","name":"obj"},"right":null}}},"isStrictStringMap":{"__symbolic":"function","parameters":["obj"],"value":{"__symbolic":"binop","operator":"&&","left":{"__symbolic":"binop","operator":"&&","left":{"__symbolic":"binop","operator":"===","left":{"__symbolic":"error","message":"Expression form not supported","line":81,"character":9},"right":"object"},"right":{"__symbolic":"binop","operator":"!==","left":{"__symbolic":"reference","name":"obj"},"right":null}},"right":{"__symbolic":"binop","operator":"===","left":{"__symbolic":"call","expression":{"__symbolic":"select","expression":{"__symbolic":"reference","name":"Object"},"member":"getPrototypeOf"},"arguments":[{"__symbolic":"reference","name":"obj"}]},"right":{"__symbolic":"call","expression":{"__symbolic":"select","expression":{"__symbolic":"reference","name":"Object"},"member":"getPrototypeOf"},"arguments":[{}]}}}},"isDate":{"__symbolic":"function","parameters":["obj"],"value":{"__symbolic":"binop","operator":"&&","left":{"__symbolic":"binop","operator":"instanceof","left":{"__symbolic":"reference","name":"obj"},"right":{"__symbolic":"reference","name":"Date"}},"right":{"__symbolic":"pre","operator":"!","operand":{"__symbolic":"call","expression":{"__symbolic":"reference","name":"isNaN"},"arguments":[{"__symbolic":"call","expression":{"__symbolic":"select","expression":{"__symbolic":"reference","name":"obj"},"member":"valueOf"}}]}}}},"looseIdentical":{"__symbolic":"function","parameters":["a","b"],"value":{"__symbolic":"binop","operator":"||","left":{"__symbolic":"binop","operator":"===","left":{"__symbolic":"reference","name":"a"},"right":{"__symbolic":"reference","name":"b"}},"right":{"__symbolic":"binop","operator":"&&","left":{"__symbolic":"binop","operator":"&&","left":{"__symbolic":"binop","operator":"&&","left":{"__symbolic":"binop","operator":"===","left":{"__symbolic":"error","message":"Expression form not supported","line":143,"character":20},"right":"number"},"right":{"__symbolic":"binop","operator":"===","left":{"__symbolic":"error","message":"Expression form not supported","line":143,"character":45},"right":"number"}},"right":{"__symbolic":"call","expression":{"__symbolic":"reference","name":"isNaN"},"arguments":[{"__symbolic":"reference","name":"a"}]}},"right":{"__symbolic":"call","expression":{"__symbolic":"reference","name":"isNaN"},"arguments":[{"__symbolic":"reference","name":"b"}]}}}},"normalizeBlank":{"__symbolic":"function","parameters":["obj"],"value":{"__symbolic":"if","condition":{"__symbolic":"call","expression":{"__symbolic":"reference","name":"isBlank"},"arguments":[{"__symbolic":"reference","name":"obj"}]},"thenExpression":null,"elseExpression":{"__symbolic":"reference","name":"obj"}}},"normalizeBool":{"__symbolic":"function","parameters":["obj"],"value":{"__symbolic":"if","condition":{"__symbolic":"call","expression":{"__symbolic":"reference","name":"isBlank"},"arguments":[{"__symbolic":"reference","name":"obj"}]},"thenExpression":false,"elseExpression":{"__symbolic":"reference","name":"obj"}}},"isJsObject":{"__symbolic":"function","parameters":["o"],"value":{"__symbolic":"binop","operator":"&&","left":{"__symbolic":"binop","operator":"!==","left":{"__symbolic":"reference","name":"o"},"right":null},"right":{"__symbolic":"binop","operator":"||","left":{"__symbolic":"binop","operator":"===","left":{"__symbolic":"error","message":"Expression form not supported","line":155,"character":24},"right":"function"},"right":{"__symbolic":"binop","operator":"===","left":{"__symbolic":"error","message":"Expression form not supported","line":155,"character":51},"right":"object"}}}},"isPrimitive":{"__symbolic":"function","parameters":["obj"],"value":{"__symbolic":"pre","operator":"!","operand":{"__symbolic":"call","expression":{"__symbolic":"reference","name":"isJsObject"},"arguments":[{"__symbolic":"reference","name":"obj"}]}}},"escapeRegExp":{"__symbolic":"function","parameters":["s"],"value":{"__symbolic":"error","message":"Expression form not supported","line":210,"character":19}}}}
{"__symbolic":"module","version":1,"metadata":{"getTypeNameForDebugging":{"__symbolic":"function","parameters":["type"],"value":{"__symbolic":"binop","operator":"||","left":{"__symbolic":"index","expression":{"__symbolic":"reference","name":"type"},"index":"name"},"right":{"__symbolic":"error","message":"Expression form not supported","line":60,"character":25}}},"isPresent":{"__symbolic":"function","parameters":["obj"],"value":{"__symbolic":"binop","operator":"!=","left":{"__symbolic":"reference","name":"obj"},"right":null}},"isBlank":{"__symbolic":"function","parameters":["obj"],"value":{"__symbolic":"binop","operator":"==","left":{"__symbolic":"reference","name":"obj"},"right":null}},"isStrictStringMap":{"__symbolic":"function","parameters":["obj"],"value":{"__symbolic":"binop","operator":"&&","left":{"__symbolic":"binop","operator":"&&","left":{"__symbolic":"binop","operator":"===","left":{"__symbolic":"error","message":"Expression form not supported","line":80,"character":9},"right":"object"},"right":{"__symbolic":"binop","operator":"!==","left":{"__symbolic":"reference","name":"obj"},"right":null}},"right":{"__symbolic":"binop","operator":"===","left":{"__symbolic":"call","expression":{"__symbolic":"select","expression":{"__symbolic":"reference","name":"Object"},"member":"getPrototypeOf"},"arguments":[{"__symbolic":"reference","name":"obj"}]},"right":{"__symbolic":"call","expression":{"__symbolic":"select","expression":{"__symbolic":"reference","name":"Object"},"member":"getPrototypeOf"},"arguments":[{}]}}}},"isDate":{"__symbolic":"function","parameters":["obj"],"value":{"__symbolic":"binop","operator":"&&","left":{"__symbolic":"binop","operator":"instanceof","left":{"__symbolic":"reference","name":"obj"},"right":{"__symbolic":"reference","name":"Date"}},"right":{"__symbolic":"pre","operator":"!","operand":{"__symbolic":"call","expression":{"__symbolic":"reference","name":"isNaN"},"arguments":[{"__symbolic":"call","expression":{"__symbolic":"select","expression":{"__symbolic":"reference","name":"obj"},"member":"valueOf"}}]}}}},"looseIdentical":{"__symbolic":"function","parameters":["a","b"],"value":{"__symbolic":"binop","operator":"||","left":{"__symbolic":"binop","operator":"===","left":{"__symbolic":"reference","name":"a"},"right":{"__symbolic":"reference","name":"b"}},"right":{"__symbolic":"binop","operator":"&&","left":{"__symbolic":"binop","operator":"&&","left":{"__symbolic":"binop","operator":"&&","left":{"__symbolic":"binop","operator":"===","left":{"__symbolic":"error","message":"Expression form not supported","line":140,"character":20},"right":"number"},"right":{"__symbolic":"binop","operator":"===","left":{"__symbolic":"error","message":"Expression form not supported","line":140,"character":45},"right":"number"}},"right":{"__symbolic":"call","expression":{"__symbolic":"reference","name":"isNaN"},"arguments":[{"__symbolic":"reference","name":"a"}]}},"right":{"__symbolic":"call","expression":{"__symbolic":"reference","name":"isNaN"},"arguments":[{"__symbolic":"reference","name":"b"}]}}}},"isJsObject":{"__symbolic":"function","parameters":["o"],"value":{"__symbolic":"binop","operator":"&&","left":{"__symbolic":"binop","operator":"!==","left":{"__symbolic":"reference","name":"o"},"right":null},"right":{"__symbolic":"binop","operator":"||","left":{"__symbolic":"binop","operator":"===","left":{"__symbolic":"error","message":"Expression form not supported","line":144,"character":24},"right":"function"},"right":{"__symbolic":"binop","operator":"===","left":{"__symbolic":"error","message":"Expression form not supported","line":144,"character":51},"right":"object"}}}},"isPrimitive":{"__symbolic":"function","parameters":["obj"],"value":{"__symbolic":"pre","operator":"!","operand":{"__symbolic":"call","expression":{"__symbolic":"reference","name":"isJsObject"},"arguments":[{"__symbolic":"reference","name":"obj"}]}}},"escapeRegExp":{"__symbolic":"function","parameters":["s"],"value":{"__symbolic":"error","message":"Expression form not supported","line":199,"character":19}}}}

@@ -588,3 +588,3 @@ import { AsyncValidatorFn, ValidatorFn } from './directives/validators';

* ```ts
* this.form.reset({first: 'name', last; 'last name'});
* this.form.reset({first: 'name', last: 'last name'});
*

@@ -591,0 +591,0 @@ * console.log(this.form.value); // {first: 'name', last: 'last name'}

@@ -16,3 +16,2 @@ /**

import { EventEmitter } from './facade/async';
import { isBlank, isPresent, normalizeBool } from './facade/lang';
import { isPromise } from './private_import_core';

@@ -41,3 +40,3 @@ /**

function _find(control, path, delimiter) {
if (isBlank(path))
if (path == null)
return null;

@@ -270,5 +269,4 @@ if (!(path instanceof Array)) {

var onlySelf = (_a === void 0 ? {} : _a).onlySelf;
onlySelf = normalizeBool(onlySelf);
this._touched = true;
if (isPresent(this._parent) && !onlySelf) {
if (this._parent && !onlySelf) {
this._parent.markAsTouched({ onlySelf: onlySelf });

@@ -288,3 +286,3 @@ }

this._forEachChild(function (control) { control.markAsUntouched({ onlySelf: true }); });
if (isPresent(this._parent) && !onlySelf) {
if (this._parent && !onlySelf) {
this._parent._updateTouched({ onlySelf: onlySelf });

@@ -301,5 +299,4 @@ }

var onlySelf = (_a === void 0 ? {} : _a).onlySelf;
onlySelf = normalizeBool(onlySelf);
this._pristine = false;
if (isPresent(this._parent) && !onlySelf) {
if (this._parent && !onlySelf) {
this._parent.markAsDirty({ onlySelf: onlySelf });

@@ -319,3 +316,3 @@ }

this._forEachChild(function (control) { control.markAsPristine({ onlySelf: true }); });
if (isPresent(this._parent) && !onlySelf) {
if (this._parent && !onlySelf) {
this._parent._updatePristine({ onlySelf: onlySelf });

@@ -329,5 +326,4 @@ }

var onlySelf = (_a === void 0 ? {} : _a).onlySelf;
onlySelf = normalizeBool(onlySelf);
this._status = PENDING;
if (isPresent(this._parent) && !onlySelf) {
if (this._parent && !onlySelf) {
this._parent.markAsPending({ onlySelf: onlySelf });

@@ -344,3 +340,2 @@ }

var _b = _a === void 0 ? {} : _a, onlySelf = _b.onlySelf, emitEvent = _b.emitEvent;
emitEvent = isPresent(emitEvent) ? emitEvent : true;
this._status = DISABLED;

@@ -350,3 +345,3 @@ this._errors = null;

this._updateValue();
if (emitEvent) {
if (emitEvent !== false) {
this._valueChanges.emit(this._value);

@@ -374,3 +369,3 @@ this._statusChanges.emit(this._status);

AbstractControl.prototype._updateAncestors = function (onlySelf) {
if (isPresent(this._parent) && !onlySelf) {
if (this._parent && !onlySelf) {
this._parent.updateValueAndValidity();

@@ -389,4 +384,2 @@ this._parent._updatePristine();

var _b = _a === void 0 ? {} : _a, onlySelf = _b.onlySelf, emitEvent = _b.emitEvent;
onlySelf = normalizeBool(onlySelf);
emitEvent = isPresent(emitEvent) ? emitEvent : true;
this._setInitialStatus();

@@ -401,7 +394,7 @@ this._updateValue();

}
if (emitEvent) {
if (emitEvent !== false) {
this._valueChanges.emit(this._value);
this._statusChanges.emit(this._status);
}
if (isPresent(this._parent) && !onlySelf) {
if (this._parent && !onlySelf) {
this._parent.updateValueAndValidity({ onlySelf: onlySelf, emitEvent: emitEvent });

@@ -418,15 +411,16 @@ }

AbstractControl.prototype._runValidator = function () {
return isPresent(this.validator) ? this.validator(this) : null;
return this.validator ? this.validator(this) : null;
};
AbstractControl.prototype._runAsyncValidator = function (emitEvent) {
var _this = this;
if (isPresent(this.asyncValidator)) {
if (this.asyncValidator) {
this._status = PENDING;
this._cancelExistingSubscription();
var obs = toObservable(this.asyncValidator(this));
this._asyncValidationSubscription = obs.subscribe({ next: function (res) { return _this.setErrors(res, { emitEvent: emitEvent }); } });
this._asyncValidationSubscription =
obs.subscribe({ next: function (res) { return _this.setErrors(res, { emitEvent: emitEvent }); } });
}
};
AbstractControl.prototype._cancelExistingSubscription = function () {
if (isPresent(this._asyncValidationSubscription)) {
if (this._asyncValidationSubscription) {
this._asyncValidationSubscription.unsubscribe();

@@ -460,5 +454,4 @@ }

var emitEvent = (_a === void 0 ? {} : _a).emitEvent;
emitEvent = isPresent(emitEvent) ? emitEvent : true;
this._errors = errors;
this._updateControlsErrors(emitEvent);
this._updateControlsErrors(emitEvent !== false);
};

@@ -487,9 +480,4 @@ /**

if (path === void 0) { path = null; }
var control = isPresent(path) && (path.length > 0) ? this.get(path) : this;
if (isPresent(control) && isPresent(control._errors)) {
return control._errors[errorCode];
}
else {
return null;
}
var control = path ? this.get(path) : this;
return control && control._errors ? control._errors[errorCode] : null;
};

@@ -504,3 +492,3 @@ /**

if (path === void 0) { path = null; }
return isPresent(this.getError(errorCode, path));
return !!this.getError(errorCode, path);
};

@@ -513,3 +501,3 @@ Object.defineProperty(AbstractControl.prototype, "root", {

var x = this;
while (isPresent(x._parent)) {
while (x._parent) {
x = x._parent;

@@ -528,3 +516,3 @@ }

}
if (isPresent(this._parent)) {
if (this._parent) {
this._parent._updateControlsErrors(emitEvent);

@@ -541,3 +529,3 @@ }

return DISABLED;
if (isPresent(this._errors))
if (this._errors)
return INVALID;

@@ -566,3 +554,3 @@ if (this._anyControlsHaveStatus(PENDING))

this._pristine = !this._anyControlsDirty();
if (isPresent(this._parent) && !onlySelf) {
if (this._parent && !onlySelf) {
this._parent._updatePristine({ onlySelf: onlySelf });

@@ -575,3 +563,3 @@ }

this._touched = this._anyControlsTouched();
if (isPresent(this._parent) && !onlySelf) {
if (this._parent && !onlySelf) {
this._parent._updateTouched({ onlySelf: onlySelf });

@@ -665,7 +653,5 @@ }

var _b = _a === void 0 ? {} : _a, onlySelf = _b.onlySelf, emitEvent = _b.emitEvent, emitModelToViewChange = _b.emitModelToViewChange, emitViewToModelChange = _b.emitViewToModelChange;
emitModelToViewChange = isPresent(emitModelToViewChange) ? emitModelToViewChange : true;
emitViewToModelChange = isPresent(emitViewToModelChange) ? emitViewToModelChange : true;
this._value = value;
if (this._onChange.length && emitModelToViewChange) {
this._onChange.forEach(function (changeFn) { return changeFn(_this._value, emitViewToModelChange); });
if (this._onChange.length && emitModelToViewChange !== false) {
this._onChange.forEach(function (changeFn) { return changeFn(_this._value, emitViewToModelChange !== false); });
}

@@ -961,3 +947,3 @@ this.updateValueAndValidity({ onlySelf: onlySelf, emitEvent: emitEvent });

* ```ts
* this.form.reset({first: 'name', last; 'last name'});
* this.form.reset({first: 'name', last: 'last name'});
*

@@ -964,0 +950,0 @@ * console.log(this.form.value); // {first: 'name', last: 'last name'}

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Packages

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc