file stringlengths 16 94 | text stringlengths 32 24.4k | vector list |
|---|---|---|
api/xmlhttprequesteventtarget/loadstart_event/index.md | API - XMLHttpRequestEventTarget - loadstart event:
Note: This feature is available in Web Workers.
The `loadstart` event is fired when a request has started to load data. | [
-1.1249957084655762,
-0.1750032603740692,
-0.4276506006717682,
-0.15186160802841187,
-0.4815906286239624,
-0.8861593008041382,
-0.030958030372858047,
0.1764783263206482,
0.25688016414642334,
-0.21373997628688812,
0.09536424279212952,
0.406185507774353,
0.1826307624578476,
-0.55553460121154... |
api/xmlhttprequesteventtarget/loadstart_event/index.md | API - XMLHttpRequestEventTarget - loadstart event - Syntax:
Use the event name in methods like `addEventListener()`, or set an event handler property.
Example:
addEventListener("loadstart", (event) => { })
onloadstart = (event) => { } | [
-0.17713618278503418,
-0.3824482262134552,
-0.14897620677947998,
0.2401580512523651,
-0.5702632665634155,
-1.2153351306915283,
0.4429912865161896,
0.07434233278036118,
-0.014394424855709076,
-0.16385354101657867,
-0.42602619528770447,
0.7723575830459595,
0.13663128018379211,
-0.38691598176... |
api/xmlhttprequesteventtarget/loadstart_event/index.md | API - XMLHttpRequestEventTarget - loadstart event - Event type:
A `ProgressEvent`. Inherits from `Event`. | [
-0.7773615121841431,
-0.36883461475372314,
0.043352484703063965,
-0.23202693462371826,
-0.8200497031211853,
-0.1961163431406021,
0.22560492157936096,
0.017154868692159653,
0.15477590262889862,
-0.4655361473560333,
-0.23429149389266968,
0.7229304313659668,
-0.13560271263122559,
-0.135687187... |
api/xmlhttprequesteventtarget/loadstart_event/index.md | API - XMLHttpRequestEventTarget - loadstart event - Examples - Usage with XMLHttpRequest - HTML:
Example:
<div class="controls">
<input
class="xhr success"
type="button"
name="xhr"
value="Click to start XHR (success)" />
<input
class="xhr error"
type="button"
name="xhr"
value="Clic... | [
-0.5266461968421936,
-0.32058221101760864,
0.1323748081922531,
0.4117084741592407,
-0.506147027015686,
-1.102239966392517,
0.25548288226127625,
-0.16405315697193146,
0.018651574850082397,
0.045906148850917816,
-0.8262962102890015,
0.6642206311225891,
0.28267011046409607,
-0.091118298470973... |
api/xmlhttprequesteventtarget/loadstart_event/index.md | API - XMLHttpRequestEventTarget - loadstart event - Examples - Usage with XMLHttpRequest - JavaScript:
Example:
const xhrButtonSuccess = document.querySelector(".xhr.success");
const xhrButtonError = document.querySelector(".xhr.error");
const xhrButtonAbort = document.querySelector(".xhr.abort");
const log = documen... | [
-0.3817276954650879,
-0.3594053089618683,
-0.2672058939933777,
0.8997883200645447,
-0.36529621481895447,
-0.670417070388794,
0.11526034772396088,
-0.034938961267471313,
0.17842435836791992,
0.3591390550136566,
-0.7807422280311584,
0.45542335510253906,
-0.14712563157081604,
0.24634423851966... |
api/xmlhttprequesteventtarget/loadstart_event/index.md | API - XMLHttpRequestEventTarget - loadstart event - Examples - Usage with XMLHttpRequestUpload:
You can use the `loadstart` event to detect the beginning of an upload. For a complete code example that uploads a file and displays a progress bar, see the main `XMLHttpRequestUpload` page.
Example:
// When the upload st... | [
0.03175603598356247,
0.03967588022351265,
0.06571067869663239,
0.886733889579773,
-0.846221923828125,
-0.5978949069976807,
-0.2550898790359497,
0.5148378014564514,
0.06744842231273651,
-0.0637303814291954,
-0.7406275868415833,
0.23433586955070496,
-0.05919049680233002,
0.33176082372665405,... |
api/xmlhttprequesteventtarget/timeout_event/index.md | API - XMLHttpRequestEventTarget - timeout event:
Note: This feature is available in Web Workers.
The `timeout` event is fired when progression is terminated due to preset time expiring. | [
-1.5006611347198486,
0.019897818565368652,
-0.32633382081985474,
0.1644526869058609,
-0.491423636674881,
-1.1326501369476318,
0.04779841750860214,
0.20518441498279572,
-0.04879670590162277,
0.17932908236980438,
0.12706464529037476,
0.5705820322036743,
-0.08706319332122803,
-0.3815918862819... |
api/xmlhttprequesteventtarget/timeout_event/index.md | API - XMLHttpRequestEventTarget - timeout event - Syntax:
Use the event name in methods like `addEventListener()`, or set an event handler property.
Example:
addEventListener("timeout", (event) => { })
ontimeout = (event) => { } | [
-0.3677615523338318,
-0.6126132011413574,
-0.08246758580207825,
0.7161370515823364,
-0.2230759710073471,
-1.5070329904556274,
0.2104712575674057,
-0.24435794353485107,
0.1268308311700821,
0.06817861646413803,
-0.3713924288749695,
0.5953807830810547,
0.031990379095077515,
-0.395389586687088... |
api/xmlhttprequesteventtarget/timeout_event/index.md | API - XMLHttpRequestEventTarget - timeout event - Event type:
A `ProgressEvent`. Inherits from `Event`. | [
-1.1906379461288452,
-0.4825614094734192,
0.2660180330276489,
0.18408764898777008,
-0.7773357629776001,
-0.547890305519104,
-0.16215063631534576,
-0.437816321849823,
0.3075132369995117,
-0.21788370609283447,
-0.2610803246498108,
0.8897285461425781,
-0.20473380386829376,
-0.2268476486206054... |
api/xmlhttprequesteventtarget/timeout_event/index.md | API - XMLHttpRequestEventTarget - timeout event - Examples - Usage with XMLHttpRequest:
Example:
const client = new XMLHttpRequest();
client.open("GET", "http://www.example.org/example.txt");
client.ontimeout = () => {
console.error("Timeout!!");
};
client.send();
You could also set up the event handler using the... | [
-1.0134344100952148,
-0.5342516899108887,
0.06873483955860138,
0.6376108527183533,
-0.49449625611305237,
-1.2422717809677124,
-0.005947837606072426,
-0.1339440941810608,
-0.0051439255475997925,
0.0209641233086586,
0.0842258408665657,
0.6556555032730103,
0.17022225260734558,
-0.516421139240... |
api/xmlhttprequesteventtarget/timeout_event/index.md | API - XMLHttpRequestEventTarget - timeout event - Examples - Usage with XMLHttpRequestUpload:
You can use the `timeout` event to detect an upload that stopped because it was too slow. For a complete code example that uploads a file and displays a progress bar, see the main `XMLHttpRequestUpload` page.
The timeout is ... | [
-0.1355193853378296,
-0.6007207036018372,
0.18346361815929413,
1.2482246160507202,
-0.4519941508769989,
-0.9685883522033691,
-0.1947374790906906,
0.4815344214439392,
0.13135989010334015,
0.1757505238056183,
-0.6827546954154968,
0.42416220903396606,
0.00829126313328743,
0.5195382237434387,
... |
api/xmlhttprequesteventtarget/error_event/index.md | API - XMLHttpRequestEventTarget - error event:
Note: This feature is available in Web Workers.
The `error` event is fired when the request encountered an error. | [
-1.1514376401901245,
-0.19838251173496246,
-0.11934562027454376,
-0.2191348671913147,
-0.2586706578731537,
-1.3084182739257812,
0.17644986510276794,
0.10237292945384979,
-0.038530152291059494,
0.10296457260847092,
0.4877694249153137,
0.3740241527557373,
0.3785412609577179,
-0.4678224623203... |
api/xmlhttprequesteventtarget/error_event/index.md | API - XMLHttpRequestEventTarget - error event - Syntax:
Use the event name in methods like `addEventListener()`, or set an event handler property.
Example:
addEventListener("error", (event) => { })
onerror = (event) => { } | [
-0.4017471969127655,
-0.4248022735118866,
-0.1056358739733696,
0.41329479217529297,
-0.335355669260025,
-1.2981168031692505,
0.2744814157485962,
-0.28134778141975403,
0.01654866337776184,
-0.011407740414142609,
-0.4008926451206207,
0.6310612559318542,
0.4111214578151703,
-0.390319287776947... |
api/xmlhttprequesteventtarget/error_event/index.md | API - XMLHttpRequestEventTarget - error event - Event type:
A `ProgressEvent`. Inherits from `Event`. | [
-1.2540773153305054,
-0.4913816452026367,
0.34244945645332336,
-0.4379687011241913,
-0.6608942747116089,
-0.5934321284294128,
-0.002056257799267769,
-0.4518583416938782,
0.15262068808078766,
-0.2684217691421509,
0.01306501030921936,
0.6974628567695618,
-0.12021669000387192,
-0.433834403753... |
api/xmlhttprequesteventtarget/error_event/index.md | API - XMLHttpRequestEventTarget - error event - Examples - Usage with XMLHttpRequest - HTML:
Example:
<div class="controls">
<input
class="xhr success"
type="button"
name="xhr"
value="Click to start XHR (success)" />
<input
class="xhr error"
type="button"
name="xhr"
value="Click to... | [
-0.46140170097351074,
-0.49277350306510925,
0.14943532645702362,
0.30385297536849976,
-0.3940558433532715,
-1.073050856590271,
0.13922502100467682,
-0.4407079219818115,
0.07541878521442413,
-0.0005321316421031952,
-0.8751273155212402,
0.6364509463310242,
0.5066335201263428,
0.1047620773315... |
api/xmlhttprequesteventtarget/error_event/index.md | API - XMLHttpRequestEventTarget - error event - Examples - Usage with XMLHttpRequest - JavaScript:
Example:
const xhrButtonSuccess = document.querySelector(".xhr.success");
const xhrButtonError = document.querySelector(".xhr.error");
const xhrButtonAbort = document.querySelector(".xhr.abort");
const log = document.qu... | [
-0.2749518156051636,
-0.5855147838592529,
-0.18965642154216766,
0.7192704081535339,
-0.2602618336677551,
-1.04154634475708,
0.16620108485221863,
-0.1789824217557907,
0.09172134101390839,
0.3161086142063141,
-0.6685298085212708,
0.3562774360179901,
0.032078638672828674,
0.12793168425559998,... |
api/xmlhttprequesteventtarget/error_event/index.md | API - XMLHttpRequestEventTarget - error event - Examples - Usage with XMLHttpRequestUpload:
You can use the `error` event to detect a problem with the upload. For a complete code example that uploads a file and displays a progress bar, see the main `XMLHttpRequestUpload` page.
Example:
// In case of an error we hide... | [
-0.41751566529273987,
-0.16816535592079163,
-0.00767304003238678,
1.019540548324585,
-0.4046839475631714,
-0.9801508188247681,
0.0034386329352855682,
0.525910496711731,
-0.3622840940952301,
0.03174945339560509,
-0.46371889114379883,
0.5243591666221619,
0.14183710515499115,
0.60183954238891... |
api/xmlhttprequesteventtarget/progress_event/index.md | API - XMLHttpRequestEventTarget - progress event:
Note: This feature is available in Web Workers.
The `progress` event is fired periodically when a request receives more data. | [
-1.3374755382537842,
-0.21343612670898438,
-0.2984464764595032,
0.00299140065908432,
-0.4851055443286896,
-0.9675127863883972,
0.26673412322998047,
0.008937224745750427,
-0.30658066272735596,
0.23676800727844238,
0.12780959904193878,
0.30627694725990295,
0.20111259818077087,
-0.30883842706... |
api/xmlhttprequesteventtarget/progress_event/index.md | API - XMLHttpRequestEventTarget - progress event - Syntax:
Use the event name in methods like `addEventListener()`, or set an event handler property.
Example:
addEventListener("progress", (event) => { })
onprogress = (event) => { } | [
-0.2514905631542206,
-0.4434742033481598,
-0.16512693464756012,
0.2539517283439636,
-0.5192992687225342,
-0.8864627480506897,
0.17226527631282806,
-0.07684066891670227,
-0.2930857837200165,
-0.06948366016149521,
-0.4306785762310028,
0.6529179215431213,
0.23967009782791138,
-0.2231234461069... |
api/xmlhttprequesteventtarget/progress_event/index.md | API - XMLHttpRequestEventTarget - progress event - Event type:
A `ProgressEvent`. Inherits from `Event`. | [
-1.0618798732757568,
-0.3909842073917389,
-0.04096738621592522,
-0.32781854271888733,
-0.6464604139328003,
-0.7697739005088806,
0.008328501135110855,
-0.37520334124565125,
0.03366777300834656,
-0.1697811782360077,
-0.17910534143447876,
0.6410794258117676,
-0.24939173460006714,
-0.203048363... |
api/xmlhttprequesteventtarget/progress_event/index.md | API - XMLHttpRequestEventTarget - progress event - Examples - Usage with XMLHttpRequest - HTML:
Example:
<div class="controls">
<input
class="xhr success"
type="button"
name="xhr"
value="Click to start XHR (success)" />
<input
class="xhr error"
type="button"
name="xhr"
value="Click... | [
-0.299288809299469,
-0.46862590312957764,
0.11475369334220886,
0.3161291480064392,
-0.4350733458995819,
-1.0194848775863647,
-0.02493457682430744,
-0.41224968433380127,
0.07922868430614471,
0.20309878885746002,
-0.7856286764144897,
0.6077368855476379,
0.28619474172592163,
0.062446050345897... |
api/xmlhttprequesteventtarget/progress_event/index.md | API - XMLHttpRequestEventTarget - progress event - Examples - Usage with XMLHttpRequest - JavaScript:
Example:
const xhrButtonSuccess = document.querySelector(".xhr.success");
const xhrButtonError = document.querySelector(".xhr.error");
const xhrButtonAbort = document.querySelector(".xhr.abort");
const log = document... | [
-0.45134472846984863,
-0.5515291690826416,
-0.2576196789741516,
0.7859812378883362,
-0.4176081120967865,
-0.9279704093933105,
0.021885767579078674,
0.2168499082326889,
-0.24164149165153503,
0.41477149724960327,
-0.8248236179351807,
0.39259153604507446,
0.0048590488731861115,
0.192232072353... |
api/xmlhttprequesteventtarget/progress_event/index.md | API - XMLHttpRequestEventTarget - progress event - Examples - Usage with XMLHttpRequestUpload:
You can use the `progress` event to get info about the progress of a lengthy upload. For a complete code example that uploads a file and displays a progress bar, see the main `XMLHttpRequestUpload` page.
Example:
// Each t... | [
0.015858905389904976,
-0.412134051322937,
0.006914176046848297,
0.547584056854248,
-0.5159063339233398,
-1.0972256660461426,
-0.07022011280059814,
0.21480005979537964,
-0.3380678594112396,
0.22391045093536377,
-0.5027118921279907,
0.8199299573898315,
-0.1788562536239624,
0.7054042220115662... |
api/xmlhttprequesteventtarget/abort_event/index.md | API - XMLHttpRequestEventTarget - abort event:
Note: This feature is available in Web Workers.
The `abort` event is fired when a request has been aborted, for example because the program called `XMLHttpRequest.abort()`. | [
-1.1641627550125122,
0.18854792416095734,
-0.22833341360092163,
0.3504228889942169,
-0.5625168085098267,
-1.1126229763031006,
0.08501490205526352,
-0.08830534666776657,
0.6134889721870422,
0.5563000440597534,
-0.5576179027557373,
0.1550862044095993,
-0.06991894543170929,
-0.012577850371599... |
api/xmlhttprequesteventtarget/abort_event/index.md | API - XMLHttpRequestEventTarget - abort event - Syntax:
Use the event name in methods like `addEventListener()`, or set an event handler property.
Example:
addEventListener("abort", (event) => { })
onabort = (event) => { } | [
-0.481795996427536,
-0.505763053894043,
0.0036279037594795227,
0.5485840439796448,
-0.41446030139923096,
-1.056343913078308,
0.16008704900741577,
-0.26432204246520996,
0.16865144670009613,
0.15196235477924347,
-0.6582786440849304,
0.31421786546707153,
-0.0338606983423233,
-0.05183554440736... |
api/xmlhttprequesteventtarget/abort_event/index.md | API - XMLHttpRequestEventTarget - abort event - Event type:
A `ProgressEvent`. Inherits from `Event`. | [
-1.1689469814300537,
-0.39056164026260376,
0.19578087329864502,
-0.13981802761554718,
-0.6264871954917908,
-0.6341139078140259,
0.07929463684558868,
-0.11209394782781601,
0.386065810918808,
0.08450053632259369,
-0.1864778697490692,
0.6486595273017883,
-0.44256293773651123,
-0.2797923684120... |
api/xmlhttprequesteventtarget/abort_event/index.md | API - XMLHttpRequestEventTarget - abort event - Examples - Usage with XMLHttpRequest - HTML:
Example:
<div class="controls">
<input
class="xhr success"
type="button"
name="xhr"
value="Click to start XHR (success)" />
<input
class="xhr error"
type="button"
name="xhr"
value="Click to... | [
-0.6405937671661377,
-0.41253015398979187,
0.2505744695663452,
0.5965583324432373,
-0.40750837326049805,
-1.0982658863067627,
0.052002228796482086,
-0.34250885248184204,
0.27290624380111694,
0.28429529070854187,
-0.8473892211914062,
0.43857860565185547,
0.27358919382095337,
0.1214860826730... |
api/xmlhttprequesteventtarget/abort_event/index.md | API - XMLHttpRequestEventTarget - abort event - Examples - Usage with XMLHttpRequest - JavaScript:
Example:
const xhrButtonSuccess = document.querySelector(".xhr.success");
const xhrButtonError = document.querySelector(".xhr.error");
const xhrButtonAbort = document.querySelector(".xhr.abort");
const log = document.qu... | [
-0.4690608084201813,
-0.46636027097702026,
-0.2181326001882553,
0.7912117838859558,
-0.10994496196508408,
-1.0829497575759888,
0.14638693630695343,
0.11756688356399536,
0.140223890542984,
0.7319622039794922,
-0.6272860169410706,
0.2830430865287781,
-0.10983432084321976,
0.32367080450057983... |
api/xmlhttprequesteventtarget/abort_event/index.md | API - XMLHttpRequestEventTarget - abort event - Examples - Usage with XMLHttpRequestUpload:
You can use the `abort` event to stop the upload before it finishes. For a complete code example that uploads a file and displays a progress bar, see the main `XMLHttpRequestUpload` page.
Example:
// In case of an abort we hi... | [
-0.5845552682876587,
-0.20990431308746338,
-0.13993987441062927,
1.3529775142669678,
-0.5636074542999268,
-0.6051713824272156,
0.048952847719192505,
0.7653046250343323,
-0.12453660368919373,
0.623230516910553,
-0.9234676361083984,
0.6229627728462219,
-0.004918832331895828,
0.61301171779632... |
api/xmlhttprequesteventtarget/loadend_event/index.md | API - XMLHttpRequestEventTarget - loadend event:
Note: This feature is available in Web Workers.
The `loadend` event is fired when a request has completed, whether successfully (after `load`) or unsuccessfully (after `abort` or `error`). | [
-0.984277069568634,
-0.21078696846961975,
-0.36381852626800537,
-0.0481221079826355,
-0.29752689599990845,
-1.1241103410720825,
0.4240993857383728,
0.39725106954574585,
-0.012886621057987213,
0.1461738646030426,
-0.32353729009628296,
0.5325155258178711,
0.5548587441444397,
-0.4911376535892... |
api/xmlhttprequesteventtarget/loadend_event/index.md | API - XMLHttpRequestEventTarget - loadend event - Syntax:
Use the event name in methods like `addEventListener()`, or set an event handler property.
Example:
addEventListener("loadend", (event) => { })
onloadend = (event) => { } | [
-0.37046393752098083,
-0.4930286407470703,
-0.17115271091461182,
0.14401063323020935,
-0.30589041113853455,
-1.2610318660736084,
0.4165087044239044,
-0.003674769774079323,
0.01804899424314499,
-0.13048455119132996,
-0.3625818192958832,
0.6892437934875488,
0.24142587184906006,
-0.3660821318... |
api/xmlhttprequesteventtarget/loadend_event/index.md | API - XMLHttpRequestEventTarget - loadend event - Event type:
A `ProgressEvent`. Inherits from `Event`. | [
-1.1711411476135254,
-0.5926129221916199,
0.018969658762216568,
-0.2200230062007904,
-0.7199261784553528,
-0.6270058155059814,
0.10706304013729095,
-0.1045270636677742,
0.15159013867378235,
-0.31574541330337524,
-0.2934325337409973,
0.7583743333816528,
-0.02407822012901306,
-0.318365216255... |
api/xmlhttprequesteventtarget/loadend_event/index.md | API - XMLHttpRequestEventTarget - loadend event - Examples - Usage with XMLHttpRequest - HTML:
Example:
<div class="controls">
<input
class="xhr success"
type="button"
name="xhr"
value="Click to start XHR (success)" />
<input
class="xhr error"
type="button"
name="xhr"
value="Click ... | [
-0.46290379762649536,
-0.15988321602344513,
0.11886940896511078,
0.38255590200424194,
-0.4656982719898224,
-1.4606009721755981,
0.3826051652431488,
-0.19116607308387756,
-0.10955781489610672,
-0.00753401592373848,
-0.9203147292137146,
0.5509622693061829,
0.32589957118034363,
-0.11830636113... |
api/xmlhttprequesteventtarget/loadend_event/index.md | API - XMLHttpRequestEventTarget - loadend event - Examples - Usage with XMLHttpRequest - JavaScript:
Example:
const xhrButtonSuccess = document.querySelector(".xhr.success");
const xhrButtonError = document.querySelector(".xhr.error");
const xhrButtonAbort = document.querySelector(".xhr.abort");
const log = document.... | [
-0.4939228296279907,
-0.5145488977432251,
-0.2924831807613373,
1.0111117362976074,
-0.48274466395378113,
-1.0717743635177612,
0.16906581819057465,
0.09178052097558975,
-0.0019833743572235107,
0.44511833786964417,
-0.9226145148277283,
0.5280939340591431,
-0.021497227251529694,
0.08163651823... |
api/xmlhttprequesteventtarget/loadend_event/index.md | API - XMLHttpRequestEventTarget - loadend event - Examples - Usage with XMLHttpRequestUpload:
You can use the `loadend` event to detect the (successful or not) termination of an upload. For a complete code example that uploads a file and displays a progress bar, see the main `XMLHttpRequestUpload` page.
Example:
// ... | [
-0.505036473274231,
-0.048894524574279785,
-0.042975228279829025,
1.0558867454528809,
-0.6360753774642944,
-0.4778088331222534,
0.016595490276813507,
0.6274062395095825,
-0.319341242313385,
0.0502425841987133,
-0.5995295643806458,
0.8302501440048218,
0.19213351607322693,
0.9206822514533997... |
api/readablestream/index.md | API - ReadableStream:
Note: This feature is available in Web Workers.
The `ReadableStream` interface of the Streams API represents a readable stream of byte data. The Fetch API offers a concrete instance of a `ReadableStream` through the `body` property of a `Response` object.
`ReadableStream` is a transferable obje... | [
0.3948941230773926,
-0.4165954887866974,
0.13122598826885223,
0.09213332831859589,
0.48711466789245605,
-1.2855594158172607,
-0.13768479228019714,
1.192625641822815,
0.25806158781051636,
0.4030960500240326,
-0.00805073045194149,
0.15843935310840607,
-0.0568435937166214,
0.18600551784038544... |
api/readablestream/index.md | API - ReadableStream - Constructor:
- `ReadableStream()`: Creates and returns a readable stream object from the given handlers. | [
-0.3288622200489044,
-0.05943071097135544,
0.40762898325920105,
0.4501546621322632,
0.4742111563682556,
-1.6871917247772217,
0.12387099862098694,
0.8349263072013855,
-0.3277692198753357,
0.35338300466537476,
-0.02464810572564602,
-0.2988550662994385,
-0.4345604479312897,
-0.142342329025268... |
api/readablestream/index.md | API - ReadableStream - Instance properties:
- `ReadableStream.locked` (read only): Returns a boolean indicating whether or not the readable stream is locked to a reader. | [
-0.03152388706803322,
-0.12897595763206482,
0.46941593289375305,
-0.3801910877227783,
0.49718594551086426,
-1.2344834804534912,
0.07848261296749115,
-0.41354063153266907,
0.6073434352874756,
-0.4252823293209076,
-0.6343262195587158,
-0.4638579487800598,
-0.10539567470550537,
0.146932914853... |
api/readablestream/index.md | API - ReadableStream - Static methods:
- `ReadableStream.from()`: Returns `ReadableStream` from a provided iterable or async iterable object, such as an array, a set, an async generator, and so on. | [
-0.1740177720785141,
-0.283773809671402,
0.2883848249912262,
0.32254719734191895,
0.5939779877662659,
-1.3015865087509155,
-0.008975503966212273,
0.30171018838882446,
0.8347228169441223,
0.011217202059924603,
-0.4689040780067444,
-0.3336188495159149,
-0.07496610283851624,
-0.41074982285499... |
api/readablestream/index.md | API - ReadableStream - Instance methods:
- `ReadableStream.cancel()`: Returns a `Promise` that resolves when the stream is canceled. Calling this method signals a loss of interest in the stream by a consumer. The supplied `reason` argument will be given to the underlying source, which may or may not use it.
- `Readabl... | [
0.3834790587425232,
-0.34817469120025635,
0.5288802981376648,
0.18838901817798615,
1.0410325527191162,
-1.2685960531234741,
0.6344627737998962,
0.4513300955295563,
-0.42840293049812317,
1.1142115592956543,
-0.18890012800693512,
-0.37152791023254395,
-0.3912641108036041,
-0.2386271804571151... |
api/readablestream/index.md | API - ReadableStream - Async iteration:
`ReadableStream` implements the async iterable protocol. This enables asynchronous iteration over the chunks in a stream using the `for await...of` syntax:
Example:
const stream = new ReadableStream(getSomeSource());
for await (const chunk of stream) {
// Do something with ... | [
1.0534451007843018,
-0.40835440158843994,
0.2850571274757385,
-0.029571503400802612,
0.5259113907814026,
-0.9944044947624207,
0.17786051332950592,
1.2782378196716309,
-0.32481783628463745,
0.37782686948776245,
-0.0758904367685318,
-0.264509916305542,
-0.40684545040130615,
0.055606983602046... |
api/readablestream/index.md | API - ReadableStream - Examples - Fetch stream:
In the following example, an artificial `Response` is created to stream HTML fragments fetched from another resource to the browser.
It demonstrates the usage of a `ReadableStream` in combination with a `Uint8Array`.
Example:
fetch("https://www.example.org")
.then((... | [
0.21570979058742523,
-0.8223190307617188,
0.4459543228149414,
0.08690394461154938,
0.3583323657512665,
-1.2669637203216553,
0.790630042552948,
0.5834026336669922,
0.17072322964668274,
0.6845223307609558,
-0.34561294317245483,
0.054408758878707886,
-0.302287220954895,
-0.0005066283047199249... |
api/readablestream/index.md | API - ReadableStream - Examples - Convert an iterator or async iterator to a stream:
The `from()` static method can convert an iterator, such as an `Array` or `Map`, or an (async) iterator to a readable stream:
Example:
const myReadableStream = ReadableStream.from(iteratorOrAsyncIterator);
On browsers that don't su... | [
1.1992415189743042,
-0.6871680617332458,
0.3511841595172882,
0.26837655901908875,
0.9034856557846069,
-1.872174620628357,
0.023075420409440994,
0.6258504986763,
0.5512942671775818,
0.7122645974159241,
0.024905629456043243,
-0.15287789702415466,
0.007407393306493759,
-0.47672969102859497,
... |
api/readablestream/index.md | API - ReadableStream - Examples - Async iteration of a stream using for await...of:
This example shows how you can process the `fetch()` response using a `for await...of` loop to iterate through the arriving chunks.
Example:
const response = await fetch("https://www.example.org");
let total = 0;
// Iterate response... | [
0.511006236076355,
-0.4921824336051941,
0.5881075859069824,
0.5697564482688904,
0.3487572968006134,
-1.430881142616272,
0.5873587131500244,
0.19497482478618622,
-0.27456921339035034,
0.17057600617408752,
-0.018851857632398605,
-0.24663977324962616,
-0.21269020438194275,
0.14047712087631226... |
api/readablestream/from_static/index.md | API - ReadableStream - from static:
Note: This feature is available in Web Workers.
The `ReadableStream.from()` static method returns a `ReadableStream` from a provided iterable or async iterable object.
The method can be used to wrap iterable and async iterable objects as readable streams, including arrays, sets, a... | [
0.1962287575006485,
-0.46322864294052124,
-0.06095253676176071,
0.3733183741569519,
0.8257903456687927,
-1.6691546440124512,
0.5481016635894775,
1.2701205015182495,
-0.04395434632897377,
0.7090712785720825,
0.05189672112464905,
0.5109536051750183,
0.15390825271606445,
-0.14816191792488098,... |
api/readablestream/from_static/index.md | API - ReadableStream - from static - Syntax:
Example:
ReadableStream.from(anyIterable) | [
-0.25783151388168335,
-0.15385591983795166,
0.8887560367584229,
-0.33762219548225403,
0.4396495223045349,
-1.6777762174606323,
-0.39048531651496887,
0.09759502112865448,
0.6919414401054382,
0.2285047024488449,
0.038524530827999115,
-0.06546188145875931,
-0.947511613368988,
-0.0699238404631... |
api/readablestream/from_static/index.md | API - ReadableStream - from static - Syntax - Parameters:
- `anyIterable`: An iterable or async iterable object. | [
-0.13317185640335083,
-0.21762114763259888,
1.0294809341430664,
-0.46672627329826355,
0.3652068078517914,
-1.7407890558242798,
-0.4753914773464203,
0.24783387780189514,
0.7443561553955078,
0.17183877527713776,
-0.278720498085022,
-0.1187058538198471,
-1.1884758472442627,
-0.090404547750949... |
api/readablestream/from_static/index.md | API - ReadableStream - from static - Syntax - Return value:
A `ReadableStream`. | [
-0.41947799921035767,
-0.45072075724601746,
0.22481593489646912,
-0.2463325560092926,
0.5367024540901184,
-1.369199275970459,
0.24642491340637207,
0.15297316014766693,
0.2864433228969574,
0.21982748806476593,
0.0669357106089592,
-0.3446849584579468,
-0.884159505367279,
0.19914022088050842,... |
api/readablestream/from_static/index.md | API - ReadableStream - from static - Syntax - Exceptions:
- `TypeError`: Thrown if the passed parameter is not an iterable or async iterable (does not define the `[Symbol.iterator]()` or `[Symbol.asyncIterator]()` method). Also thrown if, during iteration, the result of the next step is not an object or is a promise t... | [
0.09630779176950455,
-0.774359941482544,
0.5980931520462036,
0.23172786831855774,
0.18535521626472473,
-1.6760444641113281,
-0.28916803002357483,
0.2773721218109131,
0.9782297611236572,
-0.08216824382543564,
-0.36494335532188416,
0.2981569766998291,
0.32182997465133667,
-0.2879436314105987... |
api/readablestream/from_static/index.md | API - ReadableStream - from static - Examples - Convert an async iterator to a ReadableStream:
This live example demonstrates how you can convert an async iterable to a `ReadableStream`, and then how this stream might be consumed. | [
-0.05235505476593971,
-0.22682853043079376,
1.0872858762741089,
-0.2034948170185089,
0.2878250479698181,
-1.6228313446044922,
0.16083867847919464,
0.040913015604019165,
0.3849268853664398,
0.3936026394367218,
-0.2769472002983093,
-0.11628910899162292,
-0.5492146015167236,
0.046859048306941... |
api/readablestream/from_static/index.md | API - ReadableStream - from static - Examples - Convert an async iterator to a ReadableStream - HTML:
The HTML is consists of single `<pre>` element, which is used for logging.
Example:
<pre id="log"></pre> | [
-0.4515306353569031,
-0.26797547936439514,
0.48200613260269165,
-0.0524178072810173,
0.34080177545547485,
-1.780598521232605,
-0.23558592796325684,
-0.1777758002281189,
0.5743885040283203,
0.3508565425872803,
-0.6077920794487,
-0.30156028270721436,
-0.3637562096118927,
-0.19069954752922058... |
api/readablestream/from_static/index.md | API - ReadableStream - from static - Examples - Convert an async iterator to a ReadableStream - JavaScript:
The example code creates a `log()` function to write to the log HTML element.
Example:
const logElement = document.getElementById("log");
function log(text) {
logElement.innerText += `${text}\n`;
}
It then ... | [
0.6609165072441101,
-0.2787059247493744,
0.059517838060855865,
0.0200328566133976,
0.8313151001930237,
-1.2319886684417725,
0.4294288456439972,
1.1403098106384277,
-0.4008353352546692,
0.29822400212287903,
-0.05847911536693573,
-0.03450687229633331,
-0.2240557223558426,
0.02958874404430389... |
api/readablestream/from_static/index.md | API - ReadableStream - from static - Examples - Convert an Array to a ReadableStream:
This example demonstrates how you can convert an `Array` to a `ReadableStream`.
Example:
<pre id="log"></pre>
Example:
const logElement = document.getElementById("log");
function log(text) {
logElement.innerText += `${text}\n`;... | [
0.1799328476190567,
-0.5135051012039185,
0.2552888095378876,
0.13880613446235657,
0.3675380051136017,
-1.7793018817901611,
0.24570006132125854,
0.7746336460113525,
0.22995561361312866,
0.5233443975448608,
-0.10935978591442108,
-0.29338616132736206,
-0.30815303325653076,
-0.5223036408424377... |
api/readablestream/from_static/index.md | API - ReadableStream - from static - Examples - Convert an Array to a ReadableStream - JavaScript:
The iterable is just an array of strings that is passed to `ReadableStream.from()` to create the `ReadableStream`.
Example:
// An Array of vegetable names
const vegetables = ["Carrot", "Broccoli", "Tomato", "Spinach"];... | [
0.6495417356491089,
-0.8310661315917969,
0.44870203733444214,
0.5382915139198303,
0.5906918048858643,
-1.4683184623718262,
0.9299792051315308,
1.325387716293335,
-0.5320712327957153,
0.3915221691131592,
0.32670438289642334,
-0.14173278212547302,
-0.5360665321350098,
-0.14975252747535706,
... |
api/canvasrenderingcontext2d/lang/index.md | API - CanvasRenderingContext2D - lang:
The `CanvasRenderingContext2D.lang` property of the Canvas 2D API gets or sets the language of the canvas drawing context. | [
-0.5169880390167236,
-0.20432384312152863,
0.26908940076828003,
0.3686883747577667,
-0.25633156299591064,
-1.2790850400924683,
-0.6246722936630249,
0.3015076518058777,
0.2261447310447693,
-0.5909977555274963,
-0.5754654407501221,
-0.28710758686065674,
0.4960605502128601,
0.2490331530570984... |
api/canvasrenderingcontext2d/lang/index.md | API - CanvasRenderingContext2D - lang - Value:
The `lang` property can take one of the following string values:
- A `BCP 47 language tag` representing the language of the canvas context.
- The string `inherit`, in which case the language is inherited from the `lang` attribute of the originating `canvas` element or th... | [
-0.7689211964607239,
0.02953118085861206,
0.18129076063632965,
0.20651815831661224,
0.1790255904197693,
-1.718517780303955,
0.5877047181129456,
0.9640091061592102,
-0.3636397421360016,
0.22207142412662506,
0.019930515438318253,
0.19312232732772827,
0.3917590081691742,
0.05768837779760361,
... |
api/canvasrenderingcontext2d/lang/index.md | API - CanvasRenderingContext2D - lang - Description:
Sometimes, you need to set a language for a canvas rendering context so that it knows how to render language-dependent features: for example, some fonts have certain characters rendered differently in different languages. An on-screen canvas context (`CanvasRenderin... | [
-0.06324397027492523,
0.06668105721473694,
0.07890588790178299,
0.8712635636329651,
0.255693644285202,
-0.8155779838562012,
0.12271502614021301,
1.0717161893844604,
0.009768523275852203,
0.3484247624874115,
0.047234706580638885,
0.12730318307876587,
0.3220739960670471,
0.8098377585411072,
... |
api/canvasrenderingcontext2d/lang/index.md | API - CanvasRenderingContext2D - lang - Description - The `inherit` value:
When the `inherit` value is used, the language of the canvas context is inherited from the `lang` attribute of the nearest-available HTML source:
- In the case of an on-screen context, or an off-screen context that was transferred from an on-s... | [
0.20703305304050446,
0.34178367257118225,
-0.03725557029247284,
0.7626537084579468,
0.2096591293811798,
-1.2841484546661377,
0.28963708877563477,
1.218678593635559,
-0.19773492217063904,
0.2561129033565521,
-0.2438368797302246,
0.3949182629585266,
-0.0479593500494957,
0.7118804454803467,
... |
api/canvasrenderingcontext2d/lang/index.md | API - CanvasRenderingContext2D - lang - Examples - Basic usage:
Example:
const canvasElem = document.querySelector("canvas");
const ctx = canvasElem.getContext("2d");
// Get context language; returns "inherit" by default
console.log(ctx.lang);
// Set context language
ctx.lang = "en";
// Logs "en"
console.log(ctx.la... | [
-0.08445915579795837,
0.16446541249752045,
-0.503239631652832,
0.8936932682991028,
-0.36670807003974915,
-0.9665876626968384,
-0.17737489938735962,
0.19694840908050537,
-0.040335703641176224,
-0.20699316263198853,
-0.4221639931201935,
-0.4453810453414917,
0.6610152721405029,
0.128551244735... |
api/canvasrenderingcontext2d/lang/index.md | API - CanvasRenderingContext2D - lang - Examples - Demonstrating canvas context localization support:
In this example, we render a text string to a 2D canvas context in a particular font that has language-dependent ligatures. We allow the canvas context's language to be adjusted so you can see the difference in render... | [
-0.9270090460777283,
0.2919348478317261,
0.9049468040466309,
0.3597666323184967,
-0.29755109548568726,
-1.7203034162521362,
0.26117250323295593,
0.37569355964660645,
0.5819132328033447,
0.1328125298023224,
-0.29265087842941284,
-0.12828874588012695,
0.7715619206428528,
0.27215340733528137,... |
api/canvasrenderingcontext2d/lang/index.md | API - CanvasRenderingContext2D - lang - Examples - Demonstrating canvas context localization support - HTML:
The HTML features a `select` element that allows you to choose a language — `en` (English) or `tr` (Turkish) — and a `canvas` element to render to.
Example:
<p>
<label for="lang">Choose language:</label>
... | [
-0.8596235513687134,
-0.12491660565137863,
0.704833447933197,
0.874258279800415,
-0.002269633114337921,
-1.3731358051300049,
0.48687732219696045,
0.47856128215789795,
-0.19758769869804382,
0.690920352935791,
-0.0806938037276268,
-0.49060919880867004,
0.6481057405471802,
0.20142102241516113... |
api/canvasrenderingcontext2d/lang/index.md | API - CanvasRenderingContext2D - lang - Examples - Demonstrating canvas context localization support - JavaScript:
In the JavaScript, we first grab references to the `<canvas>` element, its `CanvasRenderingContext2D`, and the `<select>` element, then load the language-dependent font using the CSS Font Loading API. Onc... | [
0.3471771478652954,
0.4050462543964386,
0.08561167865991592,
0.7992141842842102,
-0.029098030179739,
-0.7607433795928955,
0.7917958498001099,
1.260944128036499,
-0.8156546354293823,
0.5595959424972534,
-0.25313273072242737,
0.057896874845027924,
0.11739765107631683,
0.28391024470329285,
... |
api/canvasrenderingcontext2d/lang/index.md | API - CanvasRenderingContext2D - lang - Examples - Language support for offscreen canvases:
This example is the similar to the previous example, except that the font is rendered to an `OffscreenCanvasRenderingContext2D` then the resulting bitmap is transferred to the on-screen `<canvas>` to display.
In addition, beca... | [
-0.6511725187301636,
0.5459685921669006,
-0.07834460586309433,
0.7410677671432495,
-0.028917424380779266,
-1.6482356786727905,
0.27854782342910767,
1.0981858968734741,
0.17496222257614136,
0.12268175184726715,
-0.31466978788375854,
0.13777518272399902,
0.6365361213684082,
0.350424408912658... |
api/canvasrenderingcontext2d/lang/index.md | API - CanvasRenderingContext2D - lang - Examples - Language support for offscreen canvases - HTML:
Example:
<p>
<label for="lang">Choose language:</label>
<select id="lang" name="lang">
<option>en</option>
<option>tr</option>
</select>
</p>
<canvas></canvas> | [
-0.5220404863357544,
0.10246548056602478,
0.22172197699546814,
0.5370084047317505,
0.23526689410209656,
-1.1776067018508911,
-0.40011247992515564,
0.3589749336242676,
0.00743933767080307,
0.15501804649829865,
-0.4378744065761566,
-0.24125456809997559,
0.6926352977752686,
0.1183445602655410... |
api/canvasrenderingcontext2d/lang/index.md | API - CanvasRenderingContext2D - lang - Examples - Language support for offscreen canvases - JavaScript:
The JavaScript works in the same way as the previous example, except that:
- The on-screen canvas context is defined as an `ImageBitmapRenderingContext`.
- We define a new `OffscreenCanvasRenderingContext2D` to dr... | [
0.19295330345630646,
0.4884263277053833,
-0.13842159509658813,
0.008302446454763412,
0.3228937089443207,
-0.47544464468955994,
0.856052041053772,
1.5237972736358643,
-0.3537397086620331,
0.369859904050827,
-0.3626885712146759,
-0.013351265341043472,
-0.21174193918704987,
0.4671828746795654... |
api/sharedworkerglobalscope/connect_event/index.md | API - SharedWorkerGlobalScope - connect event:
The `connect` event is fired in shared workers at their `SharedWorkerGlobalScope` when a new client connects.
This event is not cancelable and does not bubble. | [
-0.701629102230072,
-0.23356425762176514,
-0.1912938356399536,
0.34618744254112244,
-0.3940352499485016,
-0.7250497341156006,
-0.13601887226104736,
0.13396364450454712,
-0.7676434516906738,
0.32593435049057007,
-0.21489357948303223,
0.023537978529930115,
0.6667908430099487,
0.8026740550994... |
api/sharedworkerglobalscope/connect_event/index.md | API - SharedWorkerGlobalScope - connect event - Syntax:
Use the event name in methods like `addEventListener()`, or set an event handler property.
Example:
addEventListener("connect", (event) => { })
onconnect = (event) => { } | [
0.28024014830589294,
-0.22945919632911682,
-0.34650710225105286,
0.3677268922328949,
0.020606979727745056,
-0.7189834713935852,
-0.18190418183803558,
-0.11137519031763077,
0.07840469479560852,
0.5998343229293823,
-0.6618647575378418,
0.43998241424560547,
-0.20075947046279907,
-0.0217049084... |
api/sharedworkerglobalscope/connect_event/index.md | API - SharedWorkerGlobalScope - connect event - Event type:
A `MessageEvent`. Inherits from `Event`. | [
-0.5830963253974915,
-0.5662042498588562,
0.00014394894242286682,
-0.03882472589612007,
-0.21779008209705353,
-0.7227402925491333,
-0.23848764598369598,
0.03932712972164154,
0.06931187212467194,
0.35060736536979675,
-0.21697302162647247,
0.5365795493125916,
0.2158772498369217,
0.3658787608... |
api/sharedworkerglobalscope/connect_event/index.md | API - SharedWorkerGlobalScope - connect event - Examples:
This example shows a shared worker file — when a connection to the worker occurs from a main thread via a `MessagePort`, the `onconnect` event handler fires. The event object is a `MessageEvent`.
The connecting port can be referenced through the event object's... | [
0.37309500575065613,
0.08218709379434586,
-0.5830521583557129,
0.5008285641670227,
0.5870039463043213,
-0.7915096282958984,
-0.24397043883800507,
0.748363196849823,
-0.5631124973297119,
0.1813993752002716,
-0.07219850271940231,
0.61459881067276,
1.0582605600357056,
0.872096836566925,
0.7... |
api/sharedworkerglobalscope/connect_event/index.md | API - SharedWorkerGlobalScope - connect event - Examples - addEventListener equivalent:
You could also set up an event handler using the `addEventListener()` method:
Example:
self.addEventListener("connect", (e) => {
const port = e.ports[0];
port.onmessage = (e) => {
const workerResult = `Result: ${e.data[0... | [
-0.07137000560760498,
-0.5226391553878784,
-0.9874570369720459,
0.6441444754600525,
0.49768275022506714,
-1.102185845375061,
0.3485645651817322,
0.267901211977005,
0.43780940771102905,
0.19870944321155548,
-0.5775871276855469,
0.6067575216293335,
0.7079216837882996,
0.34433993697166443,
... |
api/xrvisibilitymaskchangeevent/index.md | API - XRVisibilityMaskChangeEvent:
Secure context: This feature is available only in secure contexts (HTTPS).
The `XRVisibilityMaskChangeEvent` of the WebXR Device API describes the portion of an `XRView` visible to the user after the view has changed, for example by specifying the eye that the view is relevant to, ... | [
0.4818282425403595,
-0.1668054759502411,
0.26739609241485596,
0.5671170353889465,
-0.22509342432022095,
-0.958958625793457,
0.5390109419822693,
1.0737911462783813,
0.13556450605392456,
0.24799178540706635,
0.4993011951446533,
0.6600207090377808,
0.3852355480194092,
0.24397942423820496,
0... |
api/xrvisibilitymaskchangeevent/index.md | API - XRVisibilityMaskChangeEvent - Constructor:
- `XRVisibilityMaskChangeEvent()` (experimental): Creates and returns a new `XRVisibilityMaskChangeEvent` object. | [
-0.8083634972572327,
-0.2991623878479004,
0.32018613815307617,
0.5467974543571472,
-0.3556388020515442,
-1.4119927883148193,
0.33514973521232605,
0.5232629776000977,
0.029769621789455414,
0.25220805406570435,
-0.5487998127937317,
-0.12121173739433289,
0.37280604243278503,
-0.34983366727828... |
api/xrvisibilitymaskchangeevent/index.md | API - XRVisibilityMaskChangeEvent - Instance properties:
In addition to properties inherited from its parent interface, `Event`, `XRVisibilityMaskChangeEvent` provides the following:
- `eye` (read only) (experimental): The eye the mask applies to.
- `index` (read only) (experimental): The index of the current `XRView... | [
0.4257490336894989,
-0.2139851599931717,
0.2782216966152191,
0.4464505910873413,
-0.26717525720596313,
-0.4539119005203247,
0.3974524438381195,
1.1301857233047485,
0.3453350067138672,
-0.047359760850667953,
0.2102711945772171,
0.26124444603919983,
0.23792749643325806,
0.5711854100227356,
... |
api/xrvisibilitymaskchangeevent/index.md | API - XRVisibilityMaskChangeEvent - Instance methods:
While `XRSessionEvent` defines no methods, it inherits methods from its parent interface, `Event`. | [
0.3526642322540283,
-0.37913963198661804,
-0.5047155022621155,
0.3226722776889801,
-0.8761667609214783,
-1.4066343307495117,
0.9831012487411499,
0.6167468428611755,
0.541395902633667,
-0.01661093719303608,
0.013310663402080536,
-0.3829519748687744,
0.1261328160762787,
0.017991505563259125,... |
api/xrvisibilitymaskchangeevent/index.md | API - XRVisibilityMaskChangeEvent - Examples - Three.js example:
This snippet shows how `visibilitymaskchange` might be used to draw only the visible portion of the `XRView` in a Three.js application. The new view must be drawn using the `XRView.projectionMatrix` of the relevant `XRView` and a default `XRRigidTransfor... | [
0.5826265811920166,
-0.049855563789606094,
-0.36429980397224426,
0.20408423244953156,
-0.005885690450668335,
-1.1061358451843262,
0.2591356635093689,
0.9957016706466675,
-0.4636009931564331,
0.5184701085090637,
-0.1622852236032486,
0.6928580403327942,
0.4665142893791199,
0.2785704433917999... |
api/mediakeysession/message_event/index.md | API - MediaKeySession - message event:
Secure context: This feature is available only in secure contexts (HTTPS).
The `message` event of the `MediaKeySession` interface fires when a message is generated by the content decryption module. | [
0.7883652448654175,
-0.07898607105016708,
-0.5613918304443359,
-0.19504877924919128,
0.3954087495803833,
-0.7377367615699768,
0.292018860578537,
1.4391839504241943,
-0.29404473304748535,
-0.2257760465145111,
0.4019429087638855,
0.641028106212616,
0.35255879163742065,
0.4958235025405884,
... |
api/mediakeysession/message_event/index.md | API - MediaKeySession - message event - Syntax:
Use the event name in methods like `addEventListener()`, or set an event handler property.
Example:
addEventListener("message", (event) => { })
onmessage = (event) => { } | [
0.38865575194358826,
-0.44017213582992554,
-0.1378525197505951,
-0.20678433775901794,
0.3205833435058594,
-1.0968809127807617,
0.07804542034864426,
0.7703507542610168,
-0.08444646000862122,
-0.27542948722839355,
-0.2546142637729645,
0.2976256012916565,
0.10645951330661774,
-0.0599322877824... |
api/mediakeysession/message_event/index.md | API - MediaKeySession - message event - Event type:
A `MediaKeyMessageEvent`. Inherits from `Event`. | [
-0.09037408232688904,
-0.10759153962135315,
-0.2594992518424988,
-0.49982261657714844,
-0.043554432690143585,
-0.8217371106147766,
0.12493996322154999,
0.5706460475921631,
-0.08901901543140411,
0.057623494416475296,
0.1050383448600769,
0.3222425878047943,
0.09079844504594803,
0.02792027592... |
api/mediakeysession/keystatuseschange_event/index.md | API - MediaKeySession - keystatuseschange event:
Secure context: This feature is available only in secure contexts (HTTPS).
The `keystatuseschange` event of the `MediaKeySession` API fires when there has been a change in the keys or their statuses within a session. | [
0.07655046880245209,
-0.3116094470024109,
-0.7139697670936584,
0.7630847096443176,
0.28134921193122864,
-0.7556890845298767,
0.06762560456991196,
1.2417851686477661,
-0.1302979439496994,
-0.1363849639892578,
0.407487154006958,
-0.2524597644805908,
0.2297302484512329,
0.35021111369132996,
... |
api/mediakeysession/keystatuseschange_event/index.md | API - MediaKeySession - keystatuseschange event - Syntax:
Use the event name in methods like `addEventListener()`, or set an event handler property.
Example:
addEventListener("keystatuseschange", (event) => { })
onkeystatuseschange = (event) => { } | [
0.4568364918231964,
-0.2312035858631134,
-0.7624621391296387,
0.6249138116836548,
-0.23533853888511658,
-1.4018282890319824,
0.209554985165596,
1.2492088079452515,
-0.12470920383930206,
-0.06466967612504959,
-0.2977828085422516,
0.11344598233699799,
0.07454726099967957,
-0.0001860931515693... |
api/mediakeysession/keystatuseschange_event/index.md | API - MediaKeySession - keystatuseschange event - Event type:
An `ExtendableEvent`. Inherits from `Event`. | [
-0.34801483154296875,
-0.42272162437438965,
-0.25760477781295776,
0.03821028023958206,
-0.6404536366462708,
-0.7938387989997864,
0.10605299472808838,
0.8902307748794556,
0.03010464459657669,
0.2424546480178833,
0.13517729938030243,
0.517440676689148,
-0.1557808816432953,
0.3231123089790344... |
api/mutationrecord/addednodes/index.md | API - MutationRecord - addedNodes:
The `MutationRecord` read-only property `addedNodes` is a `NodeList` of nodes added to a target node by a mutation observed with a `MutationObserver`. | [
0.04922425374388695,
-0.16613824665546417,
-0.7997353672981262,
0.46018490195274353,
-0.10493970662355423,
-1.1072258949279785,
0.5270498394966125,
0.5636257529258728,
0.7924663424491882,
-0.4927062392234802,
-1.1502957344055176,
-0.24410216510295868,
-0.3817002773284912,
0.590749621391296... |
api/mutationrecord/addednodes/index.md | API - MutationRecord - addedNodes - Value:
A `NodeList` containing the nodes added to the target of the mutation observed by the `MutationObserver`. | [
-0.21609388291835785,
-0.833489716053009,
-1.243057370185852,
0.7324254512786865,
-0.1688786745071411,
-0.5486727952957153,
0.66497403383255,
0.8575554490089417,
0.7231729626655579,
-0.22616221010684967,
-0.6645383238792419,
-0.04471246525645256,
-0.4740658104419708,
0.7751188278198242,
... |
api/mutationrecord/addednodes/index.md | API - MutationRecord - addedNodes - Examples - Update when adding a node:
In the following example, there are two buttons: one to add new nodes to a target node, and one to remove them. A `MutationObserver` is used to observe the target node for changes; when a change is detected, the observer calls a function, `logNe... | [
0.5099226236343384,
-0.6321547627449036,
-1.451642394065857,
0.609560489654541,
-0.2896300256252289,
-1.2129545211791992,
0.9107476472854614,
0.5252591371536255,
0.664368748664856,
-0.03653784096240997,
-0.3764244318008423,
-0.4197707772254944,
-0.07859921455383301,
1.0824795961380005,
0... |
api/mutationrecord/addednodes/index.md | API - MutationRecord - addedNodes - Examples - Update when adding a node - HTML:
Example:
<button id="add-nodes">Add a node</button>
<button id="remove-nodes">Remove a node</button>
<button id="reset">Reset</button>
<pre id="counter">Total added nodes: 0</pre>
<div id="target"></div>
Example:
#counter {
border: ... | [
-0.6978636384010315,
-0.40244925022125244,
-0.37480342388153076,
0.7401587963104248,
-0.3063291609287262,
-0.9396958947181702,
0.42761343717575073,
0.7292606830596924,
-0.1451083868741989,
0.0519578643143177,
-0.6518310904502869,
-0.1920236498117447,
-0.2481922060251236,
0.6560061573982239... |
api/mutationrecord/addednodes/index.md | API - MutationRecord - addedNodes - Examples - Update when adding a node - JavaScript:
Example:
const addNodes = document.querySelector("#add-nodes");
const removeNodes = document.querySelector("#remove-nodes");
const reset = document.querySelector("#reset");
const counter = document.querySelector("#counter");
const ... | [
0.05236724391579628,
-0.463157594203949,
-0.7190201282501221,
0.5329894423484802,
0.0570334792137146,
-0.788510262966156,
0.32754117250442505,
0.34232407808303833,
0.3639315068721771,
0.07843868434429169,
-0.6002459526062012,
-0.02491116151213646,
-0.6650324463844299,
0.6772235035896301,
... |
api/mutationrecord/removednodes/index.md | API - MutationRecord - removedNodes:
The `MutationRecord` read-only property `removedNodes` is a `NodeList` of nodes removed from a target node by a mutation observed with a `MutationObserver`. | [
-0.3475381135940552,
-0.2266588807106018,
-0.773732602596283,
0.10216638445854187,
0.29970937967300415,
-1.1813678741455078,
0.008267566561698914,
0.22840076684951782,
0.9457982778549194,
-0.086429163813591,
-0.840920627117157,
-0.2699323296546936,
-0.18473167717456818,
0.6622062921524048,... |
api/mutationrecord/removednodes/index.md | API - MutationRecord - removedNodes - Value:
A `NodeList` containing the nodes removed from the target of the mutation observed by the `MutationObserver`. | [
-0.24464543163776398,
-0.6648353934288025,
-1.1723911762237549,
0.6262966394424438,
0.04477088153362274,
-0.8230546116828918,
0.5099815130233765,
0.66462641954422,
0.5018091797828674,
-0.03493749350309372,
-0.6249057650566101,
-0.17501604557037354,
-0.21537376940250397,
0.5853883028030396,... |
api/mutationrecord/removednodes/index.md | API - MutationRecord - removedNodes - Examples - Observing removed nodes:
In the following example, there are two buttons: one to add new nodes to a target node, and one to remove them. A `MutationObserver` is used to observe the target node for changes; when a change is detected, the observer calls a function, `logRe... | [
0.07091516256332397,
-0.597344696521759,
-1.4428046941757202,
0.4884645938873291,
-0.24504783749580383,
-1.2968287467956543,
0.9310581684112549,
0.49663233757019043,
0.7385573983192444,
0.31829193234443665,
-0.5336280465126038,
-0.3685280382633209,
-0.2277933806180954,
1.1379414796829224,
... |
api/mutationrecord/removednodes/index.md | API - MutationRecord - removedNodes - Examples - Observing removed nodes - HTML:
Example:
<button id="add-nodes">Add a node</button>
<button id="remove-nodes">Remove a node</button>
<button id="reset">Reset</button>
<pre id="counter">Total removed nodes: 0</pre>
<div id="target"></div>
Example:
#counter {
border... | [
-0.9976394176483154,
-0.3842106759548187,
-0.5559011697769165,
0.6401873826980591,
-0.26042109727859497,
-1.0497956275939941,
0.22142839431762695,
0.7353321313858032,
-0.15958768129348755,
0.38857924938201904,
-0.7377111911773682,
-0.01823582872748375,
0.03496553748846054,
0.58208060264587... |
api/mutationrecord/removednodes/index.md | API - MutationRecord - removedNodes - Examples - Observing removed nodes - JavaScript:
Example:
const addNodes = document.querySelector("#add-nodes");
const removeNodes = document.querySelector("#remove-nodes");
const reset = document.querySelector("#reset");
const counter = document.querySelector("#counter");
const ... | [
0.16969172656536102,
-0.6876146197319031,
-0.5749684572219849,
0.6944381594657898,
-0.13147322833538055,
-0.9140650033950806,
0.5673829913139343,
0.252495139837265,
0.33462223410606384,
0.352285236120224,
-0.5802627205848694,
-0.11852152645587921,
-0.6199082136154175,
0.5799213647842407,
... |
api/rtccertificatestats/index.md | API - RTCCertificateStats:
The `RTCCertificateStats` dictionary of the WebRTC API is used to report information about a certificate used by an `RTCDtlsTransport` and its underlying `RTCIceTransport`.
The report can be obtained by iterating the `RTCStatsReport` returned by `RTCPeerConnection.getStats()` until you find... | [
-0.21019478142261505,
-0.4404468834400177,
-0.5799915790557861,
0.5571385622024536,
0.041961029171943665,
-1.2277133464813232,
-0.7423966526985168,
0.7009098529815674,
0.8954155445098877,
0.1647891402244568,
-1.2523726224899292,
0.23908326029777527,
0.738971471786499,
0.11835139989852905,
... |
api/rtccertificatestats/index.md | API - RTCCertificateStats - Instance properties:
- `base64Certificate`: A string containing the base-64 representation of the DER-encoded certificate.
- `fingerprint`: A string containing the certificate fingerprint, which is calculated using the hash function specified in `fingerprintAlgorithm`.
- `fingerprintAlgorit... | [
0.2647262215614319,
-0.06650684773921967,
-0.4688325822353363,
-0.15253308415412903,
0.15564242005348206,
-0.46261677145957947,
0.6653734445571899,
1.4961332082748413,
0.3050823211669922,
0.2944324016571045,
-0.6738940477371216,
0.6889727711677551,
0.2350655198097229,
0.18863599002361298,
... |
api/rtccertificatestats/index.md | API - RTCCertificateStats - Instance properties - Common instance properties:
The following properties are common to all WebRTC statistics objects (See `RTCStatsReport` for more information).
- `id`: A string that uniquely identifies the object that is being monitored to produce this set of statistics.
- `timestamp`:... | [
0.09321681410074234,
-0.19195127487182617,
-0.7543758749961853,
0.2933485805988312,
0.2901384234428406,
-1.2629643678665161,
0.7375139594078064,
1.5377568006515503,
-0.1520271599292755,
0.5396681427955627,
-0.9544711709022522,
0.4985959529876709,
0.1154550313949585,
0.3727462887763977,
0... |
api/rtccertificatestats/index.md | API - RTCCertificateStats - Examples - Basic usage:
Given a variable `myPeerConnection`, which is an instance of `RTCPeerConnection`, the code below uses `await` to wait for the statistics report, and then iterates it using `RTCStatsReport.forEach()`. It then filters the dictionaries for just those reports that have t... | [
0.17221499979496002,
-0.0771842747926712,
-1.1493556499481201,
0.5307274460792542,
0.7152222990989685,
-0.7293068170547485,
0.1807844191789627,
1.5231834650039673,
-0.006720088422298431,
0.31226789951324463,
-0.47558242082595825,
0.7479102611541748,
0.3973594903945923,
0.18538525700569153,... |
api/rtccertificatestats/issuercertificateid/index.md | API - RTCCertificateStats - issuerCertificateId:
The `issuerCertificateId` property of the `RTCCertificateStats` dictionary is a string containing the `id` of the `RTCCertificateStats` object in this report that contains the next certificate in the certificate chain.
If there are no further certificates in the chain,... | [
-0.0063851140439510345,
-0.21547932922840118,
-0.48664817214012146,
0.2539573609828949,
0.40955042839050293,
-0.7266905307769775,
0.5731828212738037,
1.0907257795333862,
0.06502486765384674,
0.8224925398826599,
-0.6642046570777893,
0.37032365798950195,
-0.33682331442832947,
0.0583484992384... |
api/rtccertificatestats/issuercertificateid/index.md | API - RTCCertificateStats - issuerCertificateId - Value:
A string, or `undefined` if the current certificate is at the end of the certificate chain. | [
-0.297223299741745,
0.3680744171142578,
-0.5525342226028442,
-0.22277851402759552,
0.37324464321136475,
-1.2437798976898193,
0.5046239495277405,
0.726247251033783,
-0.09792861342430115,
0.3060488700866699,
-0.25341182947158813,
0.25896015763282776,
-0.038303397595882416,
0.6159690618515015... |
api/xrcompositionlayer/miplevels/index.md | API - XRCompositionLayer - mipLevels:
The read-only `mipLevels` property of the `XRCompositionLayer` interface is a layer's number of mip levels in the color and texture data. See also Mipmap on Wikipedia.
The desired number of mip levels can be specified when creating layers. However, if the user agent can't create ... | [
-0.21337801218032837,
-1.010991096496582,
-0.6893393397331238,
0.13434022665023804,
0.19141384959220886,
-0.8803929686546326,
0.9319270849227905,
1.6903483867645264,
0.2962696850299835,
-0.18656766414642334,
-0.37960338592529297,
0.41349685192108154,
0.13119694590568542,
0.2232139706611633... |
api/xrcompositionlayer/miplevels/index.md | API - XRCompositionLayer - mipLevels - Value:
A number equal or smaller to the requested mip levels when a layer has been created. | [
0.01047344971448183,
-0.6052663326263428,
-0.10273576527833939,
0.4288008511066437,
0.17869216203689575,
-1.1407018899917603,
0.6363694667816162,
0.31447166204452515,
-0.40592411160469055,
-0.453200101852417,
-0.5784411430358887,
0.4811893105506897,
-0.5717293620109558,
0.30338913202285767... |
api/xrcompositionlayer/miplevels/index.md | API - XRCompositionLayer - mipLevels - Examples - Getting a layer's mip levels:
The `mipLevels` property indicates the actual number of mip levels that have been created. In this example, the desired number of 5 mip levels that had been requested for an `XRQuadLayer` could be full-filled.
Example:
let xrGLBinding = ... | [
-0.5892553329467773,
-0.9504227638244629,
-1.005950927734375,
0.6129106879234314,
0.2538951635360718,
-1.7958595752716064,
0.7288044095039368,
0.48498934507369995,
0.26093539595603943,
-0.1982424110174179,
-0.6822328567504883,
0.2786251902580261,
-0.24382703006267548,
0.6892239451408386,
... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.