aboutsummaryrefslogtreecommitdiff
path: root/files/zh-cn/web/api/textencoder/encoding
diff options
context:
space:
mode:
Diffstat (limited to 'files/zh-cn/web/api/textencoder/encoding')
-rw-r--r--files/zh-cn/web/api/textencoder/encoding/index.html49
1 files changed, 49 insertions, 0 deletions
diff --git a/files/zh-cn/web/api/textencoder/encoding/index.html b/files/zh-cn/web/api/textencoder/encoding/index.html
new file mode 100644
index 0000000000..602a16c5ff
--- /dev/null
+++ b/files/zh-cn/web/api/textencoder/encoding/index.html
@@ -0,0 +1,49 @@
+---
+title: TextEncoder.encoding
+slug: Web/API/TextEncoder/encoding
+translation_of: Web/API/TextEncoder/encoding
+---
+<p>{{APIRef("DOM")}}</p>
+
+<p>{{ SeeCompatTable }}</p>
+
+<p><strong><code>TextEncoder.encoding</code></strong> 只读属性返回一个{{domxref("DOMString")}} ,其中包含特定编码器使用的编码算法的名称。</p>
+
+<p>现在只会返回“utf-8”。</p>
+
+<h2 id="语法">语法</h2>
+
+<pre class="syntaxbox"><em>b</em> = <em>encoder</em>.encoding;</pre>
+
+<h2 id="标准">标准</h2>
+
+<table class="standard-table">
+ <tbody>
+ <tr>
+ <th scope="col">Specification</th>
+ <th scope="col">Status</th>
+ <th scope="col">Comment</th>
+ </tr>
+ <tr>
+ <td>{{SpecName('Encoding', '#dom-textencoder-encoding', 'TextEncoder.encoding')}}</td>
+ <td>{{Spec2('Encoding')}}</td>
+ <td>Initial definition.</td>
+ </tr>
+ </tbody>
+</table>
+
+<h2 id="浏览器支持">浏览器支持</h2>
+
+<div>
+<div>
+
+
+<p>{{Compat("api.TextEncoder.encoding")}}</p>
+</div>
+</div>
+
+<h2 id="另见">另见</h2>
+
+<ul>
+ <li>The {{domxref("TextEncoder")}} interface it belongs to.</li>
+</ul>