Skip to content

Latest commit

 

History

History
6 lines (5 loc) · 182 Bytes

溢出隐藏的内容后面再添加几个字.md

File metadata and controls

6 lines (5 loc) · 182 Bytes

直接统计字符个数,然后js截取

let newValue = value.substring(0,100)+"...";
let htmlValue = newValue + `<span onclick="alert('ok')">阅读全文</span>