Skip to content

Commit 1689dd1

Browse files
alexdimameganrogge
authored andcommitted
Update the loader (fixes microsoft/monaco-editor#2044)
1 parent 228a56d commit 1689dd1

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

src/vs/css.js

+8-1
Original file line numberDiff line numberDiff line change
@@ -97,7 +97,14 @@ var CSSLoaderPlugin;
9797
function CSSPlugin() {
9898
this._cssLoader = new BrowserCSSLoader();
9999
}
100-
CSSPlugin.prototype.load = function (name, req, load) {
100+
CSSPlugin.prototype.load = function (name, req, load, config) {
101+
config = config || {};
102+
var cssConfig = config['vs/css'] || {};
103+
if (cssConfig.disabled) {
104+
// the plugin is asked to not create any style sheets
105+
load({});
106+
return;
107+
}
101108
var cssUrl = req.toUrl(name + '.css');
102109
this._cssLoader.load(name, cssUrl, function (contents) {
103110
load({});

0 commit comments

Comments
 (0)