Search...
userAgent
Returns the user-agent
header as sent from the device used to make the router request.
Type:
stringRead Only
Was this helpful?
Get the `user-agent` header of the device used to make the router request
Copy Code
1export function myRouter_Router(request) {23 let userAgent = request.userAgent;4 // "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_4) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/57.0.2987.133 Safari/537.36"56}