HTML DOM Document implementation

Examples

Does this document has the feature DOM 1.0?

document.implementation.hasFeature("DOM", "1.0");
Try it Yourself »

Does this document has the feature TESLA X?

document.implementation.hasFeature("TESLA", "X");
Try it Yourself »

Description

The implementation property returns the DOMimplementation object that handles the document.

Warning!

The DOM 1 Recommendation (1998) only specified one method for this object: hasFeature().

The hasFeature() method was ment to check if a DOM module was supported by the browser:

let answer = document.implementation.hasFeature("DOM", "1.0");

Problem is: All modern browsers always return true.


Syntax

document.implementation

Return Value

Type Description
ObjectA DocumentImplementation object.
The document's implementation object.

Browser Support

document.implementation is a DOM Level 1 (1998) feature.

It is fully supported in all browsers:

Chrome Edge Firefox Safari Opera IE
Yes Yes Yes Yes Yes 9-11


Copyright 1999-2023 by Refsnes Data. All Rights Reserved.