Best practice to do curved style headings? (image vs custom code)

Hi!

I’m developing a site currently where almost all headings are like the image below:

Should I just export these as SVG and use an image, or is it worth doing custom code for this somehow?

Thanks in advance!