mirror of
https://github.com/angular/angular.git
synced 2026-09-14 13:54:52 +08:00
aff1512950
This commit adds a new option for `provideHttpClient` called `withHttpTransferCache()`. When this option is passed, requests done on the server are cached and reused during the bootstrapping of the application in the browser thus avoiding duplicate requests and reducing load time. This is the same as `TransferHttpCacheModule` in https://github.com/angular/universal/blob/main/modules/common/src/transfer_http.ts PR Close #49509
43 lines
977 B
Python
43 lines
977 B
Python
load("//tools:defaults.bzl", "jasmine_node_test", "karma_web_test_suite", "ts_library")
|
|
load("//tools/circular_dependency_test:index.bzl", "circular_dependency_test")
|
|
|
|
circular_dependency_test(
|
|
name = "circular_deps_test",
|
|
entry_point = "angular/packages/common/http/index.mjs",
|
|
deps = ["//packages/common/http"],
|
|
)
|
|
|
|
ts_library(
|
|
name = "test_lib",
|
|
testonly = True,
|
|
srcs = glob(
|
|
["**/*.ts"],
|
|
),
|
|
# Visible to //:saucelabs_unit_tests_poc target
|
|
visibility = ["//:__pkg__"],
|
|
deps = [
|
|
"//packages/common",
|
|
"//packages/common/http",
|
|
"//packages/common/http/testing",
|
|
"//packages/core",
|
|
"//packages/core/testing",
|
|
"//packages/private/testing",
|
|
"@npm//rxjs",
|
|
],
|
|
)
|
|
|
|
jasmine_node_test(
|
|
name = "test",
|
|
bootstrap = ["//tools/testing:node"],
|
|
deps = [
|
|
":test_lib",
|
|
],
|
|
)
|
|
|
|
karma_web_test_suite(
|
|
name = "test_web",
|
|
deps = [
|
|
":test_lib",
|
|
],
|
|
)
|