TextDecoder: fatal プロパティ

Baseline Widely available

This feature is well established and works across many devices and browser versions. It’s been available across browsers since January 2020.

fatalTextDecoder インターフェイスの読み取り専用プロパティで、エラーモードが fatal であるかどうかを論理値で示します。

このプロパティが true であった場合、デコーダーがデコード中に正しくない形のデータに遭遇した場合、TypeError が発生します。 false であった場合、デコーダーは無効なデータを置換文字 U+FFFD (�) で置き換えます。 このプロパティの値は TextDecoder() コンストラクターで設定されます。

論理値で、エラーモードが fatal に設定されている場合は true となります。 そうでない場合は false となり、エラーモードが replacement であることを示します。

仕様書

Specification
Encoding
# ref-for-dom-textdecoder-fatal①

ブラウザーの互換性

Report problems with this compatibility data on GitHub
desktopmobileserver
Chrome
Edge
Firefox
Opera
Safari
Chrome Android
Firefox for Android
Opera Android
Safari on iOS
Samsung Internet
WebView Android
WebView on iOS
Deno
Node.js
fatal

Legend

Tip: you can click/tap on a cell for more information.

Full support
Full support