HTML Sanitizer API - Web APIs
DRANK
The HTML Sanitizer API allow developers to take untrusted strings of HTML, and sanitize them for safe insertion into a document’s DOM.
1 comments
HTMLの挿入のinnerHTMLは、コード内のJSの実行を防げず、危険なので使うべきでない😡
codepen.io/tonkotsuboy/pe…
これを防ぐため、本日リリースのChrome 105にてSanitizer APIが実装された💐
ライブラリ無しにXSS対策が可能🥰codepen.io/tonkotsuboy/pe…e
解説
developer.mozilla.org/en-US/docs/Web…
#JavaScript https://t.co/uLBcO6lZcd