Downloads
Stars
Version
This repository contains some useful collection macros.
You can install the package via composer:
composer require bitsnbolts/laravel-collection-macros
replaceInKeys
Do a find and replace on all the keys of the collection.
$data = new Collection(['foo_bar' => 1]);
$data->replaceInKeys('_', ' '); // Collection(['foo bar' => 1])
composer test
Please see CHANGELOG for more information what has changed recently.
Please see CONTRIBUTING for details.
The MIT License (MIT). Please see License File for more information.