logoalt Hacker News

nulltraceyesterday at 11:06 PM1 replyview on HN

Browsers already treat the same SVG differently depending on how you embed it. <img> strips scripts and external resource loads. <object> and inline don't. People test with img tags, looks fine, then someone switches the embed method and everything opens up.


Replies

OneDeuxTriSeiGotoday at 1:01 AM

it'd be nice if there was a way to declare in the URL that a given SVG could only be treated as an image so that you could safely open SVG urls, etc without exposing yourself to the dangers of embed/inline.

show 1 reply