laravel-device-detector maintained by visernic
Description
A Laravel wrapper for the DeviceDetector library
Author
Last update
2025/11/04 04:24
(dev-main)
License
Downloads
1
Laravel Device Detector
A Laravel wrapper for the Matomo DeviceDetector library.
🚀 Installation
composer require visernic/laravel-device-detector
⚙️ Configuration
Publish config file:
php artisan vendor:publish --provider="Visernic\\DeviceDetector\\DeviceDetectorServiceProvider" --tag="config"
🧠 Usage Example
use DeviceDetector;
$device = DeviceDetector::detectRequest(request());
if ($device->isBot()) {
// handle bot
} else {
$client = $device->getClient();
$os = $device->getOs();
$deviceName = $device->getDeviceName();
$brand = $device->getBrandName();
$model = $device->getModel();
}
🧑💻 Author
Md Mostafa Niloy (Visernic)
📧 mostafa@visernic.com
🌐 https://visernic.com
🪪 License
MIT © 2025 Visernic