下面是我的html和Java脚本页面,并且html没有使用js源
内容简介
WebView(
javascriptMode: JavascriptMode.unrestricted,
initialUrl: "html/index.html",
)
index.html
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta http-equiv="X-UA-Compatible" content="ie=edge">
<title>HTML</title>
</head>
<body>
<script src="js/main.js"></script>
<h2>Hi</h2>
<script>
alert('html')
</script>
</body>
</html>
main.js
alert("inside js");
正在显示警报html
,但警报inside js
无效
已经尝试颤振webView
和WebviewScaffold