Skip to content

Commit fe35279

Browse files
author
jgillespie
committed
feat: remove useRelPreload option and make default behavior if supported
1 parent 11a96b6 commit fe35279

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

src/index.js

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -113,7 +113,6 @@ class MiniCssExtractPlugin {
113113
this.options = Object.assign(
114114
{
115115
filename: '[name].css',
116-
useRelPreload: false,
117116
},
118117
options
119118
);
@@ -325,9 +324,8 @@ class MiniCssExtractPlugin {
325324
}
326325
);
327326

328-
const supportsPreload = this.options.useRelPreload
329-
? '(function() { try { return document.createElement("link").relList.supports("preload"); } catch(e) { return false; }}());'
330-
: 'false;';
327+
const supportsPreload =
328+
'(function() { try { return document.createElement("link").relList.supports("preload"); } catch(e) { return false; }}());';
331329
return Template.asString([
332330
source,
333331
'',

0 commit comments

Comments
 (0)