Page tree
Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

Version 1 Current »


targets  에 해당하는 위치의 텍스트를 text 로 모두 교체합니다. 


Parameters:

NameTypeDescription
actionNameString액션 이름
textString교체할 텍스트
targetsObject[]

[{ id: {String}, startIndex: {Number}, endIndex: {Number} }, .....]

  • id: Paragraph Id
  • startIndex: 변경할 텍스트의 start index
  • endIndex: 변경할 텍스트의 end index


Example:

editor.execCommand('replaceTextByIndex', 'text', [
	{ id: 'paragraphId1', startIndex: 0, endIndex: 3 },
	{ id: 'paragraphId2', startIndex: 5, endIndex: 15 }
]);
  • No labels