小程序 怎么不能用js的方法 contains
我使用js里面的方法判断是否包含某个对象时:使用
var str1 = "hellomsg" if(str1.contains('hello')){ console.log("yes") }else{ console.log("no") } |
时 ,怎么会报****** contains is not a function
小程序里面没有这个方法么?
那我该如何去处理这个逻辑,微信提供了什么方法?
求解
