# solid-performance/1.3.0/src/functions/config.php

Solid Performance – Your No-Code Caching, Performance, &amp; Page Speed Solution, version 1.3.0. 33 lines.

- Page: https://pluginprobe.com/plugins/solid-performance/1.3.0/code/src/functions/config.php
- Raw: https://pluginprobe.com/plugins/solid-performance/1.3.0/raw/src/functions/config.php
- Modified: 2024-09-17T15:49:36+00:00

Line numbers below start at 1. Link to a line or a range by appending a fragment to the
page URL, for example `https://pluginprobe.com/plugins/solid-performance/1.3.0/code/src/functions/config.php#L10-L20`.

```php
<?php
/**
 * Global functions that provide access to the plugin configuration.
 *
 * @since 0.1.0
 *
 * @package SolidWP\Performance
 */

use SolidWP\Performance\Config\Config;

if ( ! defined( 'ABSPATH' ) ) {
	exit;
}

/**
 * Returns the config that is created from a set of defaults, site settings, and network settings.
 *
 * @since 0.1.0
 *
 * @param string $key The key to retrieve from the config in dot notation.
 *
 * @return mixed
 */
function swpsp_config_get( string $key ) {
	// In versions < 1.1.0, advanced-cache.php does not have the app.php require and fatal errors.
	if ( ! function_exists( 'swpsp_plugin' ) ) {
		require_once __DIR__ . '/app.php';
	}

	return swpsp_plugin()->container()->get( Config::class )->get( $key );
}

```
