electron/spec/fixtures/pages/webview-no-node-integration-on-window.html
2016-04-21 11:49:42 -07:00

23 lines
606 B
HTML

<!DOCTYPE html>
<html>
<head>
<script>
document.addEventListener('DOMContentLoaded', function () {
var windowUrl = decodeURIComponent(window.location.search.substring(3))
var wv = new WebView()
wv.setAttribute('nodeintegration', 'yes')
wv.setAttribute('src', windowUrl)
wv.setAttribute('style', 'display:inline-block; width:200px; height:200px')
wv.addEventListener('console-message', function(e) {
window.answer(e.message)
})
document.body.appendChild(wv)
})
</script>
</head>
<body>
</body>
</html>