Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

It does seem like a weirdly bad result. I got something more sensible that used DOMParser when I gave GPT-5 the following prompt:

> Write a JavaScript function for sanitizing arbitrary untrusted HTML input before setting a DOM element’s innerHTML attribute.

I won’t post it here in case someone tries to use it, but it wasn’t just doing regex munging.



Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: