Question d’entretien chez Close

In vanilla javascript how do you handle cross site scripting?

Réponse à la question d'entretien

Utilisateur anonyme

10 sept. 2024

To be honest I don't remember because I haven't injected user input into the browser, maybe ever, in vanilla javascript and would utilized React and Vue to handle that. If I had to allow user input I would use React's dangerouslySetInnerHTML and some 3rd party package to sanitize the input.

1