mirror of
https://github.com/wassname/CanvasTextWrapper.git
synced 2026-06-27 17:13:51 +08:00
allow this to be used w/ Browserify
This commit is contained in:
@@ -5,7 +5,7 @@
|
||||
* Copyright (c) 2014 Vadim Namniak
|
||||
*/
|
||||
|
||||
(function() {
|
||||
(function(root) {
|
||||
'use strict';
|
||||
|
||||
var EL_WIDTH,EL_HEIGHT,MAX_TXT_WIDTH,MAX_TXT_HEIGHT;
|
||||
@@ -284,5 +284,9 @@
|
||||
}
|
||||
};
|
||||
|
||||
window.CanvasTextWrapper = CanvasTextWrapper;
|
||||
})();
|
||||
if ('module' in root && 'exports' in module) {
|
||||
module.exports = CanvasTextWrapper;
|
||||
} else {
|
||||
root.CanvasTextWrapper = CanvasTextWrapper;
|
||||
}
|
||||
})(this);
|
||||
|
||||
Vendored
+1
-1
File diff suppressed because one or more lines are too long
Reference in New Issue
Block a user