企业🤖AI智能体构建引擎,智能编排和调试,一键部署,支持知识库和私有化部署方案 广告
## containsStrict方法:严格判断指定元素是否存在 此方法和[contains](https://ihavenolimitations.xyz/collections/contains.md)方法类似,但是它却是使用了「严格」来比较所有值。 基本使用 ~~~ $collection = collect([ ['product' => 'Desk', 'price' => 200], ['product' => 'Chair', 'price' => 100], ]); dd($collection->containsStrict('price', '100')); // false ~~~ 如上例所示,数组值存在,但是值类型不一致也返回false