ergent
v1.1.0
Published
Get the user agent to use, respecting the package.json and navigator.userAgent
Downloads
5
Maintainers
Readme
Ergent
Get the user agent to use, respecting the package.json and navigator.userAgent
Install
npm install ergent
Usage
const userAgent = require("ergent");
userAgent; // In Node.js
//=> 'myPackage v1.0.0'
userAgent; // In a browser
//=> 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/77.0.3865.120 Safari/537.36'
API
ergent
Type: string
The user agent to be used.