Download the PHP package nowo-tech/cookie-consent-bundle without Composer
On this page you can find all versions of the php package nowo-tech/cookie-consent-bundle. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Informations about the package cookie-consent-bundle
Cookie Consent Bundle
⭐ Found this useful? Install from Packagist · Give it a star on GitHub so more developers can find it.
Symfony bundle that renders a GDPR cookie consent modal with category toggles, optional per-cookie selection, cookie inventory, AJAX form submission, optional consent logging, and configurable Doctrine table prefix.
Frontend behavior is implemented in TypeScript and built with Vite (make assets → src/Resources/public/nowo-consent-modal.js).
This bundle is FrankenPHP worker mode friendly, including when the kernel is not reset between requests (reset_kernel false). See the FrankenPHP worker audit.
|
Consent banner — two-step modal with page overlay |
Admin — cookie inventory per consent profile |
Admin — profile settings with section tabs |
Features
- GDPR modal — category toggles, optional per-cookie selection, AJAX submit, TypeScript + Vite (
nowo-consent-modal.js) and standalone CSS (nowo-cookie-consent.css, CSP-friendly). - Themes —
ui_theme: bootstrap(default) ortailwind; dual FrankenPHP demos. - Cookie inventory — definitions in YAML and/or Doctrine; optional consent logging with configurable table prefix.
- Admin UI —
/cookie-consent-config(profile, behavior, appearance, modals, route targeting) plus CRUD for cookie definitions; built on the UiKit 2.0 page scaffolds (REQ-UI-003): themed once throughnowo_ui_kit(layouts, theme slots, tokens) like every Nowo bundle; no CDN assets (TEMPLATES). - Preferences bubble — reopen consent after the first choice.
- Route targeting —
render_routes/skip_render_routes; helpersnowo_cookie_consent_should_render()/nowo_cookie_consent_render(). - Database config —
use_database_configso the admin UI can override YAML at runtime; profile copy vianowo_cookie_consent_trans(). - Cold-start — cooperates with SiteBackupBundle when the schema is not ready yet; the "table exists" probe is memoized per worker (
schema_ready_cache_ttl, default 60 s) so public pages skip it after warm-up. - CSP nonce — bundle
<script>tags carry the request attributecsp_nonce(nowo-tech convention); JS-injected<style>copies the loader script nonce; no inline handlers or inlinestyleattributes. - Worker-safe — RequestStack / ManagerRegistry per call; runtime memos cleared on every main request.
Quick start
Install public assets:
Demo
demo/symfony8/— FrankenPHP Symfony 8 app with Bootstrap 5demo/symfony8-tailwind/— same demo with Tailwind CSS andui_theme: tailwind
See Demo with FrankenPHP for development vs. production worker mode.
Documentation
- Installation
- Configuration
- Usage
- Contributing
- Code of Conduct
- Changelog
- Upgrading
- Release
- Security
- Engram
- Spec-driven development
- GitHub Spec Kit
Additional documentation
- PSR evaluation (REQ-CS-007)
- Demo with FrankenPHP
- FrankenPHP worker audit
- GitHub Actions CI requirements
Tests and coverage
| Language | Lines (approx.) | Command |
|---|---|---|
| PHP | 99.39% line coverage on src/ (gate ≥99%; run make test-coverage to refresh). See docs/COVERAGE.md. |
make test-coverage |
| TypeScript | 97.19% lines (min of statements/branches/functions/lines: 90.34%, gate ≥90%) | make test-ts |
PHP coverage target is ≥99% lines (prefer 100%; see docs/COVERAGE.md). TypeScript coverage enforces a minimum of 90% (Vitest thresholds + .scripts/ts-coverage-percent.sh).
License
This bundle is released under the MIT License.
All versions of cookie-consent-bundle with dependencies
ext-dom Version *
doctrine/doctrine-bundle Version ^2.10 || ^3.0
doctrine/orm Version ^3.7
nowo-tech/form-kit-bundle Version ^2.13
nowo-tech/ui-kit-bundle Version ^2.5.1
psr/clock Version ^1.0
psr/log Version ^1.0 || ^2 || ^3
symfony/form Version ^7.4 || ^8.0
symfony/framework-bundle Version ^7.4 || ^8.0
symfony/http-kernel Version ^7.4 || ^8.0
symfony/routing Version ^7.4 || ^8.0
symfony/security-core Version ^7.4 || ^8.0
symfony/security-csrf Version ^7.4 || ^8.0
symfony/translation Version ^7.4 || ^8.0
symfony/twig-bundle Version ^7.4 || ^8.0
symfony/validator Version ^7.4 || ^8.0
twig/extra-bundle Version ^3.12
twig/string-extra Version ^3.12