angular/packages/core/src/view
Benedikt Meurer 9af18c2fd0 perf(core): be more consistent about typeof checks (#28400)
When testing whether `value` is an object, use the ideal sequence of
strictly not equal to `null` followed by `typeof value === 'object'`
consistently. Specifically there's no point in using double equal with
`null` since `undefined` is ruled out by the `typeof` check.

Also avoid the unnecessary ToBoolean check on `value.ngOnDestroy` in
`hasOnDestroy()`, since the `typeof value.ngOnDestroy === 'function'`
will only let closures pass and all closures are truish (with the
notable exception of `document.all`, but that shouldn't be relevant
for the `ngOnDestroy` hook).

PR Close #28400
2019-01-29 11:50:47 -08:00
..
element.ts fix(core): do not clear element content when using shadow dom (#24861) 2018-08-30 21:33:13 -07:00
entrypoint.ts build: extract interface and util sub compilation from core (#28028) 2019-01-10 16:31:44 -08:00
errors.ts build: extract interface and util sub compilation from core (#28028) 2019-01-10 16:31:44 -08:00
index.ts feat(compiler): introduce TestBed.overrideTemplateUsingTestingModule 2017-11-06 14:12:30 -08:00
ng_content.ts refactor(core): add a checkIndex to the compiler view nodes 2017-10-04 14:55:54 -07:00
ng_module.ts perf(core): be more consistent about typeof checks (#28400) 2019-01-29 11:50:47 -08:00
provider.ts build: extract interface and util sub compilation from core (#28028) 2019-01-10 16:31:44 -08:00
pure_expression.ts refactor(core): add a checkIndex to the compiler view nodes 2017-10-04 14:55:54 -07:00
query.ts refactor(core): add a checkIndex to the compiler view nodes 2017-10-04 14:55:54 -07:00
refs.ts fixup! fix(ivy): add missing @nocollapse annotation to __NG_ELEMENT_ID__ fields (#28050) (#28066) 2019-01-11 16:24:03 -08:00
services.ts build: extract interface and util sub compilation from core (#28028) 2019-01-10 16:31:44 -08:00
text.ts refactor(core): add a checkIndex to the compiler view nodes 2017-10-04 14:55:54 -07:00
types.ts build: extract interface and util sub compilation from core (#28028) 2019-01-10 16:31:44 -08:00
util.ts build: extract interface and util sub compilation from core (#28028) 2019-01-10 16:31:44 -08:00
view.ts fix(core): ensure init lifecycle events are called (#20258) 2017-11-10 13:47:39 -08:00
view_attach.ts style: typos fixed - https://github.com/vlajos/misspell-fixer (#22975) 2018-03-27 14:51:53 -04:00