Insert image or video at the caret position.
When there is a selection, the selected block is deleted and image or video is inserted.
Parameters:
Name | Type | Description |
---|---|---|
actionName | String | 'insertDrawingObjectURL' image and video URL inserting API |
url | String | URL of the image or video to insert |
type | String | Defining type of inserting image or video: 'Image', 'Video' |
Example:
editor.execCommand('insertDrawingObjectByURL', 'https://image.url/image', 'Image');