Home  >  Q&A  >  body text

javascript - js insert a newline/ before the bracket in a paragraph of text

What should I do if I want to add a line break before the pet skill bracket ()?

Or make the words ‘(pet skill)’ smaller

仅有的幸福仅有的幸福2663 days ago1046

reply all(4)I'll reply

  • 怪我咯

    怪我咯2017-07-05 10:38:51

    Regular matching, add a newline character in front of each (

    reply
    0
  • 扔个三星炸死你

    扔个三星炸死你2017-07-05 10:38:51

    后台拿到数据后,字符串匹配到( 在它之前插入</br>
    用v-html="content"形式填入
    

    reply
    0
  • 女神的闺蜜爱上我

    女神的闺蜜爱上我2017-07-05 10:38:51

    写个filter用正则把NAME里面的括号里面的字取出来,然后再进行操作。

    reply
    0
  • 天蓬老师

    天蓬老师2017-07-05 10:38:51

    filter, then cut the string from ‘(’ and add a br

    reply
    0
  • Cancelreply