終点

終点 (fetch)

仕様書

分類

[17] 終点の分類

文脈

[18] 終点が参照される場面

[37] fetch で使われる要求終点の値は、 fetch の呼び出し元で決定されます。

[35] Request オブジェクトには destination IDL属性 (プロパティー) があって要求終点を参照できます。 しかし Request コンストラクターfetch メソッドの引数にこれに相当するものはなく、 スクリプトから終点を明示的に指定する方法はありません。

[36] <link rel=preload> などで使われる <link as> 属性には potential destination を指定することになっています。 これを通じて間接的に終点を指定することはできます。

関連

[12] potential destination なるものもありますが、 少し認められる値が違います。

歴史

導入

[3] 要求終点は、要求文脈を細かく分解した結果導入されました。

[13] Expand Request.destination · whatwg/fetch@6b9cdaa ( 版) https://github.com/whatwg/fetch/commit/6b9cdaa9be7acd2b8074c74823981ef994d17857

[1] Expand Request.destination · whatwg/fetch@6b9cdaa ( 版) https://github.com/whatwg/fetch/commit/6b9cdaa9be7acd2b8074c74823981ef994d17857

[2] expand Request.destination with more granular values by igrigorik · Pull Request #211 · whatwg/fetch ( 版) https://github.com/whatwg/fetch/pull/211

[4] Make script fetching more correct with regard to request destinations · whatwg/html@6dc9c9e ( 版) https://github.com/whatwg/html/commit/6dc9c9e1efcc3122294fb015e4a4eea66456a611

[5] XMLHttpRequest uses the default destination ( (annevk著, )) https://github.com/whatwg/xhr/commit/4be9ce5bc7abcf544a2f0f5ebed9b17fcbb0dad9

[6] "subresource" destination doesn't exist · Issue #71 · whatwg/xhr ( ()) https://github.com/whatwg/xhr/issues/71

[7] Align Fetch's destination concept with changes in Fetch (sideshowbarker著, ) https://github.com/whatwg/html/commit/5e8f96a85d182d36c177db0d6fdde58b4ded86d4

[8] Add the "as" attribute for the <link> element (sideshowbarker著, ) https://github.com/whatwg/html/commit/2381476ea6143d835f08a3a82e6634b215cb60ea

[9] Split up media into video, audio and track (yoavweiss著, ) https://github.com/whatwg/fetch/commit/ba175cf1100045da83ed0d7768629653aa979c20

[10] Creating Safari Content-Blocking Rules () https://developer.apple.com/library/content/documentation/Extensions/Conceptual/ContentBlockingRules/CreatingRules/CreatingRules.html#//apple_ref/doc/uid/TP40016265-CH2-SW1

The value associated with this key is an array of strings representing the resource types that the rule should match. If not specified, the rule matches all resource types. The strings describes how the browser intends to use the resource, not necessarily the type of the resource itself. For example, <img src="something.css"> is identified as an image. Valid values for resource-type are:

document

image

style-sheet

script

font

raw (Any untyped load, such as XMLHttpRequest)

svg-document

media

popup

型の吸収

[15] 終点が細分化された結果、と区別する必要がなくなったとして、 両者は統合されました。

[16] Fold request type into destination (annevk著, ) https://github.com/whatwg/fetch/commit/d7052e2b6d24d04caa2cea8ef664923ecdb1e35c

[19] Fold request type into destination · Issue #581 · whatwg/fetch () https://github.com/whatwg/fetch/issues/581

[20] Fold request type into destination by annevk · Pull Request #582 · whatwg/fetch () https://github.com/whatwg/fetch/pull/582

[21] Replace Request type with destination by yoavweiss · Pull Request #11 · w3c/webappsec-mixed-content () https://github.com/w3c/webappsec-mixed-content/pull/11

[22] Replace request type with destination (yoavweiss著, ) https://github.com/w3c/webappsec-mixed-content/commit/f052b819f0724a577379bbc7abba80fbc30cb307

[23] Fetch removes type in favor of just destination (annevk著, ) https://github.com/whatwg/html/commit/5f59b7a73d450e244a573e5916deb1c2037c1366

[24] Fetch removes type in favor of just destination by annevk · Pull Request #2949 · whatwg/html () https://github.com/whatwg/html/pull/2949

[25] Editorial: correct CSP column (annevk著, ) https://github.com/whatwg/fetch/commit/a4290d1dbe93120a345f95932640c0a9180780b5

[26] Editorial: correct CSP column by annevk · Pull Request #588 · whatwg/fetch () https://github.com/whatwg/fetch/pull/588

[27] Editorial: remove "serviceworker" from RequestDestination (martinthomson著, ) https://github.com/whatwg/fetch/commit/22f9bf4275bf10d152282925bc29d0182f9f051a

[28] "serviceworker" in the RequestDestination enum · Issue #602 · whatwg/fetch () https://github.com/whatwg/fetch/issues/602

[29] Remove "serviceworker" from RequestDestination by martinthomson · Pull Request #603 · whatwg/fetch () https://github.com/whatwg/fetch/pull/603

[30] Replace Request.type based logic with Request.destination (#231) (yoavweiss著, ) https://github.com/w3c/webappsec-csp/commit/6638ad4a69933fe824575edf96348c6ec6eb7251

[31] Replace Request.type based logic with Request.destination by yoavweiss · Pull Request #231 · w3c/webappsec-csp () https://github.com/w3c/webappsec-csp/pull/231

[32] Add audioworklet and paintworklet as destinations (bfgeek著, ) https://github.com/whatwg/fetch/commit/8ab040a62c993a3f730da333a3f0ae42fc341d14

[33] Adds "audioworklet" and "paintworklet" as destinations. by bfgeek · Pull Request #527 · whatwg/fetch () https://github.com/whatwg/fetch/pull/527

[34] Request.destination for `<link rel=prefetch>` · Issue #658 · whatwg/fetch () https://github.com/whatwg/fetch/issues/658