PHPackages                             pointybeard/helpers-functions-arrays - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. pointybeard/helpers-functions-arrays

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

pointybeard/helpers-functions-arrays
====================================

A collection of helpful functions related to arrays and array manipulation

1.0.1(7y ago)04.1k↑33.3%2MITPHPPHP &gt;=5.6.6

Since May 11Pushed 7y ago1 watchersCompare

[ Source](https://github.com/pointybeard/helpers-functions-arrays)[ Packagist](https://packagist.org/packages/pointybeard/helpers-functions-arrays)[ Docs](https://github.com/pointybeard/helpers-functions-arrays)[ RSS](/packages/pointybeard-helpers-functions-arrays/feed)WikiDiscussions master Synced 3w ago

READMEChangelogDependencies (2)Versions (3)Used By (2)

PHP Helpers: Array Functions
============================

[](#php-helpers-array-functions)

- Version: v1.0.1
- Date: May 11 2019
- [Release notes](https://github.com/pointybeard/helpers-functions-arrays/blob/master/CHANGELOG.md)
- [GitHub repository](https://github.com/pointybeard/helpers-functions-arrays)

A collection of helpful functions related to arrays and array manipulation

Installation
------------

[](#installation)

This library is installed via [Composer](http://getcomposer.org/). To install, use `composer require pointybeard/helpers-functions-arrays` or add `"pointybeard/helpers-functions-arrays": "~1.0"` to your `composer.json` file.

And run composer to update your dependencies:

```
$ curl -s http://getcomposer.org/installer | php
$ php composer.phar update

```

### Requirements

[](#requirements)

There are no particuar requirements for this library other than PHP 5.6 or greater.

To include all the [PHP Helpers](https://github.com/pointybeard/helpers) packages on your project, use `composer require pointybeard/helpers` or add `"pointybeard/helpers": "~1.0"` to your composer file.

Usage
-----

[](#usage)

This library is a collection of helpful functions related to arrays and array manipulation. They are included by the vendor autoloader automatically. The functions have a namespace of `pointybeard\Helpers\Functions\Arrays`

The following functions are provided:

- `array_is_assoc(array $input) : bool`
- `array_remove_empty(array $input, int $depth=null) : ?array`
- `array_insert_at_index(array &$array, int $index, mixed ...$additions) : void`

Example usage:

```
