Improve resizing window

This commit is contained in:
Ben van Hartingsveldt 2024-12-02 12:52:14 +01:00
parent 332daccbe6
commit 25682560ea
No known key found for this signature in database
GPG key ID: 261AA214130CE7AB

View file

@ -43,6 +43,11 @@
<script>
const globe = Globe();
window.addEventListener('resize',function(event){
globe.height(event.target.innerHeight);
globe.width(event.target.innerWidth);
});
globe(document.getElementById('globe'));
globe.backgroundImageUrl('//unpkg.com/three-globe/example/img/night-sky.png');