# ConfigBuilder

> Builds Foxy configuration from Composer's project and global settings.

[API reference](/docs/api/index.md) › [Foxy](/docs/extensions/foxy/reference/index.md) › [Config](/docs/extensions/foxy/reference/config/index.md) › ConfigBuilder

| abstract class | `Foxy\Config\ConfigBuilder` |
| --- | --- |
| Source | [`src/Config/ConfigBuilder.php`](https://github.com/php-forge/foxy/blob/main/src/Config/ConfigBuilder.php#L18) |

Builds Foxy configuration from Composer's project and global settings.

## Methods

| Method | Description | Defined by |
| --- | --- | --- |
| [`build()`](#method-build) static | Build the config of plugin. | `ConfigBuilder` |

## Method details

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

```php
public static function build(Composer\Composer $composer, array $defaults = [], Composer\IO\IOInterface|null $io = null): Foxy\Config\Config
```

Build the config of plugin.

**Parameters**

| Parameter | Type | Description |
| --- | --- | --- |
| `$composer` | `Composer\Composer` | The composer. |
| `$defaults` | `array` | The default values. |
| `$io` | `Composer\IO\IOInterface\|null` | The composer input/output. |

**Returns**

[`Config`](/docs/extensions/foxy/reference/config/config/index.md)

**Throws**

- `Seld\JsonLint\ParsingException`