Skip to main content

progress_event_ctor

Function progress_event_ctor 

Source
pub(crate) fn progress_event_ctor(
    it: &mut Interp,
    t: Value,
    a: &[Value],
) -> Result<Value, Value>
Expand description

new ProgressEvent(type, options)(丸ごと未対応だった。xhr. dispatchEvent(new ProgressEvent('progress', {loaded, total}))/ fetch 進捗イベントのシミュレーション定番パターン)。基底の Event プロパティは event_ctor を再利用し、lengthComputable/loaded/ total を追加する。