resist / device
Simple mobile detector
Installs: 1 857
Dependents: 0
Suggesters: 0
Security: 0
Stars: 0
Watchers: 1
Forks: 0
Open Issues: 0
Requires
- php: ^8.2
- symfony/http-foundation: ^5.4|^6.0|^7.0
- twig/twig: ^3.3
README
Simple mobile detector for Symfony+Twig
Based on Fat Free Framework's Audit class.
Install:
composer require resist/device
Usage: use as injected service.
Register optinal Twig is_mobile()
function as extension :
# config/service.yaml resist\Device\Device: resist\Device\TwigDevice: tags: [ 'twig.extension' ]