New alternatives to innerHTML have been implemented in browsers. The setHTML function is a safe method that does not execute script, while setHTMLUnsafe is an unsafe method that poses a risk of XSS attacks. The Sanitizer API helps put the naming of setHTMLUnsafe in context. The setHTMLUnsafe function is useful for declarative
•3m read time• From fullystacked.net
3 Comments
Sort: