antidot-fw/no-floc-middleware

Antidot Framework PSR-15 NO FLoC Middleware

Fund package maintenance!
kpicaza

Installs: 15

Dependents: 0

Suggesters: 0

Security: 0

Stars: 1

Watchers: 1

Forks: 1

Open Issues: 1

pkg:composer/antidot-fw/no-floc-middleware

1.0.3 2021-06-05 12:00 UTC

This package is auto-updated.

Last update: 2025-09-29 02:43:50 UTC


README

Scrutinizer Code Quality Code Coverage Type Coverage Build Status

PSR-15 middleware to opting your Website out of Google's FLoC Network

Installation

Using composer

composer require antidot-fw/no-floc-middleware

Using Laminas config Aggregator

it install the library automatically

Usage

In Antidot, Mezzio or any other PSR-15 middleware application, add it to the global pipeline.

<?php

declare(strict_types=1);

use Antidot\Application\Http\Application;
use Antidot\Application\Http\Middleware\ErrorMiddleware;
use Antidot\Application\Http\Middleware\RouteDispatcherMiddleware;
use Antidot\Application\Http\Middleware\RouteNotFoundMiddleware;
use Antidot\Logger\Application\Http\Middleware\ExceptionLoggerMiddleware;
use Antidot\Logger\Application\Http\Middleware\RequestLoggerMiddleware;
+use Antidot\NoFLoC\NoFLoCMiddleware;

return static function (Application $app) : void {
+    $app->pipe(NoFLoCMiddleware::class)
    $app->pipe(ErrorMiddleware::class);
    $app->pipe(ExceptionLoggerMiddleware::class);
    $app->pipe(RequestLoggerMiddleware::class);
    $app->pipe(RouteDispatcherMiddleware::class);
    $app->pipe(RouteNotFoundMiddleware::class);
};