mirror of
https://github.com/xiaoyifang/goldendict-ng.git
synced 2024-11-30 13:24:05 +00:00
opt: make custom javascript delay execution
This commit is contained in:
parent
6efdb09b1a
commit
1418f9ab9e
|
@ -209,7 +209,7 @@ body { background: #242525; }
|
||||||
|
|
||||||
// load the `article-style.js` in user's config folder
|
// load the `article-style.js` in user's config folder
|
||||||
if ( auto userJsFile = Config::getUserJsFileName(); userJsFile.has_value() ) {
|
if ( auto userJsFile = Config::getUserJsFileName(); userJsFile.has_value() ) {
|
||||||
result += fmt::format( FMT_COMPILE( R"(<script src="file://{}"></script>)" ), userJsFile.value() );
|
result += fmt::format( FMT_COMPILE( R"(<script src="file://{}" defer></script>)" ), userJsFile.value() );
|
||||||
}
|
}
|
||||||
|
|
||||||
result += "</head><body>";
|
result += "</head><body>";
|
||||||
|
|
Loading…
Reference in a new issue