This is the demo for Bleach, a whitelist-based HTML sanitizing library that escapes or strips markup and attributes. Enter a sample payload in the textarea below and watch it sanitize in the textarea and iframe below.
write unsanitized textarea value to DOM
bleach.clean textarea value then write result to DOM
clean when dirty HTML changes
Dirty HTML
Clean HTML
Clean DOM