TextEncoder:TextEncoder() 建構函式

Baseline 已廣泛支援

此特性已相當成熟,可在許多裝置和瀏覽器版本上使用。自 ⁨2020 年 1 月⁩ 起,所有主流瀏覽器均已支援。

注意:此功能在 Web Workers 中可用。

TextEncoder() 建構函式返回一個新的 TextEncoder 物件。

語法

js
new TextEncoder()

引數

無。

規範

規範
編碼
# ref-for-dom-textencoder①

瀏覽器相容性

另見