browser-detector

0.1.2 • Public • Published

NPM Version Build Status

browser-dectector

A wrapper over ua-parser-js that will also add the detected classes to the html element

Install

npm i --save browser-dectector

Usage

var env = require('browser-dectector');
// after the module has been required
// the html element will have the classes for the browser, os, device and engine
// this is useful to add certain classes only to a given browser
// mostly because of msie9-msie10 is still out there
 
// env.browser.name
// env.browser.version
// env.device
// env.engine
// check for https://www.npmjs.com/package/ua-parser-js

License

MIT

Changelog

Changelog

Package Sidebar

Install

npm i browser-detector

Weekly Downloads

1

Version

0.1.2

License

MIT

Last publish

Collaborators

  • royriojas