You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@amjadaliup
I think what you need to use is the stripIgnoreTag attribute, which you can set like this:
constsource=`some text..<script>alert(1);`;consthtml=filterXSS(source,{whiteList: {},// just make sure that the whiteList does not contain scriptstripIgnoreTag: true,// filter out all HTML not in the whitelist});
@lumburr
Thank you for your answer. But I need to remove body content of the script tag also. That is not possible with these 2 ways.
I'm using stripIgnoreTagBody: ['script'] for that.
I given stripIgnoreTagBody option as ['script'] and given input is like,
And got out put as:-
I only need output like:-
how can I remove [removed] text from output.
Not:- if I give [removed] in input that will be in output.
Thanks in advance
The text was updated successfully, but these errors were encountered: