Refactor your code to functional style with PhpStorm 2018.1

How many times you wrote code like this to achieve a simple purpose? Mapping values of an array: $result = []; foreach ($items as $key => $item) {    $result[$key] = func($item); } Filtering: $result = []; foreach ($items as $key => $item) {    if (condition($item)) {        $result[$key] = $item;    } } Or reducing an array … Continue reading Refactor your code to functional style with PhpStorm 2018.1