I didn’t have the opportunity to test it, but according to this post you can copy html from the preview mode in Obsidian.