From 63591da04cf3d2cf25178ebebe1f8b72a88aa758 Mon Sep 17 00:00:00 2001 From: Vincent Voyer Date: Sun, 24 May 2015 22:41:24 +0200 Subject: [PATCH] fix: exports both as global and browser props --- src/bowser.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/bowser.js b/src/bowser.js index 1c0137b..bfdb4aa 100644 --- a/src/bowser.js +++ b/src/bowser.js @@ -1,5 +1,8 @@ !function (name, definition) { - if (typeof module != 'undefined' && module.exports) module.exports = definition() + if (typeof module != 'undefined' && module.exports) { + module.exports = definition() + module.exports['browser'] = definition() + } else if (typeof define == 'function' && define.amd) define(definition) else this[name] = definition() }('bowser', function () {