Display SVG in Jupyter notebook


I forgot how to do this. I have an SVG image in


and I want to display it in a Jupyter notebook. But as a graphic, not like this:

I tried the obvious


but no luck:

FileIO.File{FileIO.DataFormat{:UNKNOWN}}("/tmp/t.svg") couldn't be recognized by FileIO.

although that does work for PNG images (after loading FileIO).

I’m working on Julia v0.6.


One answer is:

open("/tmp/test.svg") do f
   display("image/svg+xml", readstring(f))

Kind of obvious now! :slight_smile: