v10.11.0
找到数组中给定的表达式值为 true 的第一个元素,如果没有这样的元素则返回 nil。对于下面的 members 数组:
1 | const members = [ |
输入
1 | {{ members | find_exp: "item", "item.graduation_year == 2014" | json }} |
输出
1 | {"graduation_year":2014,"name":"John"} |
v10.11.0
找到数组中给定的表达式值为 true 的第一个元素,如果没有这样的元素则返回 nil。对于下面的 members 数组:
1 | const members = [ |
输入
1 | {{ members | find_exp: "item", "item.graduation_year == 2014" | json }} |
输出
1 | {"graduation_year":2014,"name":"John"} |