This is also supported through the UI. In the editor…
Click/tap image upload icon
Click/tap “from the web”
Click/tap “show more”
Enter URL for image. Enter URL for link.
Done: