angular/packages/service-worker/worker/testing
Kristiyan Kostadinov ea61ec2562 feat(core): support TypeScript 4.4 (#43281)
Adds support for TypeScript 4.4. High-level overview of the changes made in this PR:

* Bumps the various packages to `typescript@4.4.2` and `tslib@2.3.0`.
* The `useUnknownInCatchVariables` compiler option has been disabled so that we don't have to cast error objects explicitly everywhere.
* TS now passes in a third argument to the `__spreadArray` call inside child class constructors. I had to update a couple of places in the runtime and ngcc to be able to pick up the calls correctly.
* TS now generates code like `(0, foo)(arg1, arg2)` for imported function calls. I had to update a few of our tests to account for it. See https://github.com/microsoft/TypeScript/pull/44624.
* Our `ngtsc` test setup calls the private `matchFiles` function from TS. I had to update our usage, because a new parameter was added.
* There was one place where we were setting the readonly `hasTrailingComma` property. I updated the usage to pass in the value when constructing the object instead.
* Some browser types were updated which meant that I had to resolve some trivial type errors.
* The downlevel decorators tranform was running into an issue where the Closure synthetic comments were being emitted twice. I've worked around it by recreating the class declaration node instead of cloning it.

PR Close #43281
2021-09-23 14:49:19 -07:00
..
BUILD.bazel build: rules_nodejs 0.26.0 & use @npm instead of @ngdeps now that downstream angular build uses angular bundles (#28871) 2019-02-28 12:06:36 -08:00
cache.ts test(service-worker): make mock implementations more similar to actual ones (#37922) 2020-07-09 09:44:57 -07:00
clients.ts test(service-worker): better align mock client implementations with actual implementations (#42736) 2021-07-08 10:28:22 -07:00
events.ts feat(core): support TypeScript 4.4 (#43281) 2021-09-23 14:49:19 -07:00
fetch.ts refactor(service-worker): ensure compatibility with noImplicitOverride (#42512) 2021-07-12 13:11:16 -07:00
mock.ts feat(service-worker): add the option to prefer network for navigation requests (#38565) 2020-09-22 09:29:20 -07:00
scope.ts refactor(service-worker): ensure compatibility with noImplicitOverride (#42512) 2021-07-12 13:11:16 -07:00
utils.ts refactor(service-worker): make SwTestHarness.envIsSupported() a standalone function (#42736) 2021-07-08 10:28:22 -07:00