Jhernandez has uploaded a new change for review. ( https://gerrit.wikimedia.org/r/380506 )
Change subject: Perf: Defer scripts to avoid blocking HTML parsing ...................................................................... Perf: Defer scripts to avoid blocking HTML parsing By using defer, scripts will still be run in order as they were specified but they won't block the HTML parsing. See: * https://html.spec.whatwg.org/multipage/scripting.html#attr-script-defer * http://www.growingwiththeweb.com/2014/02/async-vs-defer-attributes.html Change-Id: Ib5d7b5d2695adac2fa85b2eb3947487073e32109 --- M src/server/components/html-page.tsx 1 file changed, 1 insertion(+), 1 deletion(-) git pull ssh://gerrit.wikimedia.org:29418/marvin refs/changes/06/380506/1 diff --git a/src/server/components/html-page.tsx b/src/server/components/html-page.tsx index 86a4b2b..844f7b1 100644 --- a/src/server/components/html-page.tsx +++ b/src/server/components/html-page.tsx @@ -33,7 +33,7 @@ </head> <body> <div id="root">{children}</div> - {assets.map(path => <script type="text/javascript" src={path} />)} + {assets.map(path => <script type="text/javascript" src={path} defer />)} </body> </html> ); -- To view, visit https://gerrit.wikimedia.org/r/380506 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: Ib5d7b5d2695adac2fa85b2eb3947487073e32109 Gerrit-PatchSet: 1 Gerrit-Project: marvin Gerrit-Branch: master Gerrit-Owner: Jhernandez <[email protected]> _______________________________________________ MediaWiki-commits mailing list [email protected] https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
