From 33058f2b292b3a581333bdfb21b8f671898c5060 Mon Sep 17 00:00:00 2001 From: Peter Bengtsson Date: Tue, 8 Dec 2020 14:40:17 -0500 Subject: initial commit --- files/ja/web/api/document/compatmode/index.html | 64 +++++++++++++++++++++++++ 1 file changed, 64 insertions(+) create mode 100644 files/ja/web/api/document/compatmode/index.html (limited to 'files/ja/web/api/document/compatmode') diff --git a/files/ja/web/api/document/compatmode/index.html b/files/ja/web/api/document/compatmode/index.html new file mode 100644 index 0000000000..a5b29c7712 --- /dev/null +++ b/files/ja/web/api/document/compatmode/index.html @@ -0,0 +1,64 @@ +--- +title: Document.compatMode +slug: Web/API/Document/compatMode +tags: + - API + - DOM + - Document + - Property + - Reference +translation_of: Web/API/Document/compatMode +--- +
{{ ApiRef("DOM") }}
+ +

Document.compatMode プロパティは、文書が Quirks モード (互換モード) か標準準拠モードのどちらで表示されているかを示します。

+ +

構文

+ +
const mode = document.compatMode
+
+ +

+ +

列挙値で、次の値を取ります。

+ + + +
+

注: これらのモードはすべて標準で定義されましたので、より古い "standards" および "almost standards" の名前は無意味であり、もう標準では使用されません。

+
+ +

+ +
if (document.compatMode == "BackCompat") {
+  // 互換モード
+}
+
+ +

仕様書

+ + + + + + + + + + + + + + + + +
仕様書状態備考
{{SpecName('DOM WHATWG', '#dom-document-compatmode','compatMode')}}{{Spec2('DOM WHATWG')}}
+ +

ブラウザーの互換性

+ + + +

{{Compat("api.Document.compatMode")}}

-- cgit v1.2.3-54-g00ecf