Skip to content

Commit

Permalink
feat(http): allow customization of the HttpTransferCache.
Browse files Browse the repository at this point in the history
`provideClientHydration()` accepts new `HydrationFeature` : `HttpTransferCacheOptions`.

`withHttpTransferCacheOptions` accepts an option object:
* `includeHeaders` : list of headers entries to keep in the cache with the request
* `filter` a callback to determine if a request should be cached
* `includePostRequests`: to include POST requests in the allowed methods

Implements some of the features requested in #50117
  • Loading branch information
JeanMeche authored and AndrewKushnir committed Oct 5, 2023
1 parent ced66d4 commit cbd7ede
Show file tree
Hide file tree
Showing 14 changed files with 759 additions and 52 deletions.
2 changes: 2 additions & 0 deletions goldens/public-api/common/http/errors.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@

// @public
export const enum RuntimeErrorCode {
// (undocumented)
HEADERS_ALTERED_BY_TRANSFER_CACHE = 2801,
// (undocumented)
MISSING_JSONP_MODULE = -2800
}
Expand Down

0 comments on commit cbd7ede

Please sign in to comment.