Popup '</script>' in JS will make JS mistakenly think that this is an end tag and an exception appears.
As shown in the following code
We used alert to pop up the '</script> string in the <script> block, but it was mistakenly thought it was an end tag, and the VIM also changed its color. Running results
Since the string is regarded as the end tag, an exception appears, which is obviously not the result we want. We just need to process the code a little to achieve it.
Use the plus sign link string in '</script>', and then look at the running results in '</scr'+'ipt>'
The program is normal, and the string '</script>' is correctly popped up. In JS, if the string uses a plus sign equals to concatenate, the number uses a plus sign equals to add.