Introduction
XSS prevention stops bad code from running in your web pages. It keeps users safe from hackers who try to steal information or break your site.
When showing user comments or messages on a webpage
When displaying data that comes from outside your app, like form inputs
When including any text that users can change or add
When building pages that mix code and user content
When you want to keep your website secure and trustworthy