Browse Source

remove comments from inlined stylesheets

Gildas 6 năm trước cách đây
mục cha
commit
7adf26e0c9
1 tập tin đã thay đổi với 1 bổ sung1 xóa
  1. 1 1
      lib/single-file/single-file-core.js

+ 1 - 1
lib/single-file/single-file-core.js

@@ -822,7 +822,7 @@ this.SingleFileCore = this.SingleFileCore || (() => {
 					}
 					let stylesheet;
 					try {
-						stylesheet = cssTree.parse(stylesheetContent);
+						stylesheet = cssTree.parse(Util.removeCssComments(stylesheetContent));
 					} catch (error) {
 						// ignored
 					}