Skip to content

Commit 8e3f0f0

Browse files
author
jgillespie
committed
Small changes
1 parent 9f56caa commit 8e3f0f0

File tree

1 file changed

+3
-6
lines changed

1 file changed

+3
-6
lines changed

src/index.js

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -352,9 +352,6 @@ class MiniCssExtractPlugin {
352352
]),
353353
'}',
354354
'var linkTag = document.createElement("link");',
355-
//JG: EDIT
356-
//'linkTag.type = "text/css";',
357-
//'linkTag.rel = "stylesheet";',
358355
'linkTag.rel = "preload";',
359356
'linkTag.as = "style";',
360357
'linkTag.onload = resolve;',
@@ -386,10 +383,10 @@ class MiniCssExtractPlugin {
386383
'}).then(function() {',
387384
Template.indent([
388385
'var execLinkTag = document.createElement("link");',
389-
'execLinkTag.rel = "stylesheet";',
390386
`execLinkTag.href = ${mainTemplate.requireFn}.p + ${linkHrefPath};`,
391-
'var body = document.getElementsByTagName("body")[0];',
392-
'body.appendChild(execLinkTag);',
387+
'execLinkTag.rel = "stylesheet";',
388+
'execLinkTag.type = "text/css";',
389+
'document.body.appendChild(execLinkTag);',
393390
'installedCssChunks[chunkId] = 0;'
394391
]),
395392
'}));',

0 commit comments

Comments
 (0)