1. Go to this page and download the library: Download cubicl/php-structure-check library. Choose the download type require.
2. Extract the ZIP file and open the index.php.
3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
cubicl / php-structure-check example snippets
$ new ObjectType([
'foo' => new StringType(),
'bar' => new IntType(),
'buzz' => new AnyType(),
'foobar' => new NullableType(new StringType()),
'nested' => new ObjectType([
'foobar' => new StringType(),
]),
])
);