jadu/twig-array-extension
最新稳定版本:1.0.0
Composer 安装命令:
composer require jadu/twig-array-extension
包简介
Provides Twig extensions to retrive or exclude specific keys/value pairs from an array
README 文档
README
Filters to work with arrays prior to markup output, allowing you to exclude known keys, or only return specified keys. The filters are designed to be very permissive and won't throw any warnings or errors if the supplied keys do not exist.
Typically used in conjunction with Pulsar's attribute parser extension.
Exclude from Array
Returns a filtered array with the specified keys removed.
Multiple items can be provided, space separated.
arrayToModify|exclude('itemToExclude')
Only from Array
Returns only the items present in the filter list based on a case insensitive search
Multiple items can be provided, space separated.
arrayToModify|only('itemToInclude')
统计信息
- 总下载量: 37
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 0
- 点击次数: 0
- 依赖项目数: 1
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2023-09-18