此页面由社区从英文翻译而来。了解更多并加入 MDN Web Docs 社区。

View in English Always switch to English

TextDecoderStream.ignoreBOM

Baseline Widely available

This feature is well established and works across many devices and browser versions. It’s been available across browsers since ⁨2022年9月⁩.

TextDecoderStream 接口的只读属性 ignoreBOM 返回一个 boolean,表示是否忽略字节顺序标记(BOM)。

一个 boolean,初始值是 false

示例

js
stream = new TextDecoderStream();
console.log(stream.ignoreBOM); // returns false

规范

Specification
Encoding
# textdecoder-ignore-bom-flag

浏览器兼容性