Property | Type | Description | |
---|---|---|---|
$config | Object containing configuration settings for asset compressor |
Method | Description | |
---|---|---|
__construct ( |
Constructor | |
__invoke ( Psr\Http\Message\ServerRequestInterface $request, Psr\Http\Message\ResponseInterface $response, callable $next ) : Psr\Http\Message\ResponseInterface | Get an asset or delegate to the next middleware |
Method | Description | |
---|---|---|
getName ( |
Returns the build name for a requested asset | |
mapType ( |
Map an extension to a content type | |
respond ( Psr\Http\Message\ResponseInterface $response, string $contents, |
Respond with the asset. |
public __construct ( |
||
$config | The config object to use. If null, \AssetCompress\ConfigFinder::loadAll() will be used. |
public __invoke ( Psr\Http\Message\ServerRequestInterface $request, Psr\Http\Message\ResponseInterface $response, callable $next ) : Psr\Http\Message\ResponseInterface | ||
$request | Psr\Http\Message\ServerRequestInterface | The request. |
$response | Psr\Http\Message\ResponseInterface | The response. |
$next | callable | Callback to invoke the next middleware. |
return | Psr\Http\Message\ResponseInterface | A response |
protected respond ( Psr\Http\Message\ResponseInterface $response, string $contents, |
||
$response | Psr\Http\Message\ResponseInterface | The response to augment |
$contents | string | The asset contents. |
$build | The build target. | |
return | Psr\Http\Message\ResponseInterface |