gpt4 book ai didi

javascript - 加载特定 Javascript 后显示页面

转载 作者:行者123 更新时间:2023-11-28 01:13:01 25 4
gpt4 key购买 nike

如果某个特定的 javascript 未完全加载,我不想显示 html 页面内容。我想在加载此 javascript 时显示空白页。 Javascript 位于 .js 文件中,因此在 html 页面中它看起来像这样:

<script src = "file.js"></script>

最佳答案

将script标签放入html文档的head元素中,例如

<!doctype html>
<html>
<head>
<script src="file.js"></script>
</head>
<body>
</body>
</html>

关于javascript - 加载特定 Javascript 后显示页面,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/52013701/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com