mirror of
https://github.com/wavetermdev/xterm.js.git
synced 2026-08-05 13:43:48 -07:00
Remove __dirname usage from loadAddon
This commit is contained in:
+1
-1
@@ -642,7 +642,7 @@ Terminal.prototype.open = function(parent) {
|
||||
Terminal.loadAddon = function(addon, callback) {
|
||||
if (typeof exports === 'object' && typeof module === 'object') {
|
||||
// CommonJS
|
||||
return require(__dirname + '/../addons/' + addon);
|
||||
return require('../addons/' + addon);
|
||||
} else if (typeof define == 'function') {
|
||||
// RequireJS
|
||||
return require(['../addons/' + addon + '/' + addon], callback);
|
||||
|
||||
Reference in New Issue
Block a user