ie-version

0.1.0 • Public • Published

ie-version

Checks the Internet Explorer's version

The module uses feature detection and detects from IE6 up to IE11. Furthermore, it also checks if Internet Explorer is being emulated by changing the document mode.

Only AMD and CommonJS module loaders are supported. This means that the module cannot be registered into the window object. Feel free to adapt it to your needs.

The module returns an object with the following properties:

  • ie : Number | null
    The Internet Explorer's version. Versions lower than 6 return 6. If the browser is not Internet Explorer, returns null.
  • emulated : Boolean
    If Internet Explorer is being emulated by changing the document mode, returns true, otherwise false.
require (["path/to/ie-version"], function (ie){
  alert ("version: " + ie.version + ", emulated: " + ie.emulated);
});

/ie-version/

    Package Sidebar

    Install

    npm i ie-version

    Weekly Downloads

    715

    Version

    0.1.0

    License

    MIT

    Last publish

    Collaborators

    • gagle