HTMLPreElement

Baseline Widely available

This feature is well established and works across many devices and browser versions. It’s been available across browsers since July 2015.

HTMLPreElement インターフェイスは、(継承によって利用できる HTMLElement インターフェイスのものに加えて)整形済みテキストのブロック (<pre>) を操作するための固有のプロパティやメソッドを公開します。

EventTarget Node Element HTMLElement HTMLPreElement

インスタンスプロパティ

親である HTMLElement から継承したプロパティがあります。

HTMLPreElement.width 非推奨;

long 値で、古い width 属性を反映し、<pre> 要素の固定長の長さを指定します。

インスタンスメソッド

固有のメソッドはありません。親である HTMLElement から継承したメソッドがあります。

仕様書

Specification
HTML
# htmlpreelement

ブラウザーの互換性

Report problems with this compatibility data on GitHub
desktopmobile
Chrome
Edge
Firefox
Opera
Safari
Chrome Android
Firefox for Android
Opera Android
Safari on iOS
Samsung Internet
WebView Android
WebView on iOS
HTMLPreElement
width
Deprecated

Legend

Tip: you can click/tap on a cell for more information.

Full support
Full support
Deprecated. Not for use in new websites.

関連情報

  • このインターフェイスを実装している HTML 要素: <pre>