# PhpInfoTocEntry

> Typed view-model for one entry in the phpinfo TOC sidebar.

[API reference](/docs/api/index.md) › [Debug Core](/docs/extensions/debug-core/reference/index.md) › [PhpInfo](/docs/extensions/debug-core/reference/phpinfo/index.md) › PhpInfoTocEntry

| final readonly class | `PHPForge\Debug\PhpInfo\PhpInfoTocEntry` |
| --- | --- |
| Source | [`src/PhpInfo/PhpInfoTocEntry.php`](https://github.com/php-forge/debug-core/blob/main/src/PhpInfo/PhpInfoTocEntry.php#L10) |

Typed view-model for one entry in the phpinfo TOC sidebar.

## Properties

| Property | Type | Description | Defined by |
| --- | --- | --- | --- |
| <span id="property-slug"></span>`$slug` readonly constructor | `string` | Anchor slug ('phpinfo-overview', 'phpinfo-apcu', ...) consumed by the TOC anchor and the section id. | `PhpInfoTocEntry` |
| <span id="property-title"></span>`$title` readonly constructor | `string` | Display title ('Overview', 'apcu', 'Core', ...). | `PhpInfoTocEntry` |

## Methods

| Method | Description | Defined by |
| --- | --- | --- |
| [`__construct()`](#method-__construct) | Creates a phpinfo sidebar table-of-contents entry. | `PhpInfoTocEntry` |

## Method details

### __construct() <span id="method-__construct"></span>

```php
public function __construct(string $title, string $slug)
```

Creates a phpinfo sidebar table-of-contents entry.

**Parameters**

| Parameter | Type | Description |
| --- | --- | --- |
| `$title` | `string` |  |
| `$slug` | `string` |  |