Page tree

Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Status
colourYellow
titleRELEASE 2.11.0 OR ABOVE

Position을 기준으로 HTML Element를 반환합니다. Position이 지정되지 않은 경우 현재 캐럿 위치의 HTML Element를 반환합니다Returns an HTML Element based on Position. If Position is not specified, returns the HTML Element at the current caret position.


Parameters:

Name

Type

Attribute

Description

position

Position
[ Optional ] Selection에서 Position 정보. 이 값이 지정되지 않으면 현재 캐럿의 위치정보로 처리됩니다 Position information in Selection. If this value is not specified, it is treated as the current caret position information.

Return:

TypeDescription
HTML ElementPosition에 해당하는 HTML Element corresponding to Position



Example:

Code Block
languagejs
themeEmacs
titleposition을 지정하지 않은 경우
var element = editor.getHTMLElement();
console.log(element.innerHTML);

...