Browse Source

resizeable

star7th 5 years ago
parent
commit
291212354b
2 changed files with 12 additions and 2 deletions
  1. 4 1
      web/index.html
  2. 8 1
      web_src/index.html

+ 4 - 1
web/index.html

@@ -4,4 +4,7 @@
       "server": window.location.protocol +'//'+ window.location.host + window.location.pathname+ '../server/index.php?s=',
       //"lang" :'en'
       "lang" :'zh-cn'
-  }</script><link href=./static/css/app.e842f35bd266ed8d58f34947618d6d93.css rel=stylesheet></head><body class=grey-bg><div id=app></div><script type=text/javascript src=./static/js/manifest.96627ad77791cdcff695.js></script><script type=text/javascript src=./static/js/vendor.e142ae298b8919d4a6df.js></script><script type=text/javascript src=./static/js/app.0a0c74c87f48b871ebfd.js></script></body></html>
+  }</script><link href=./static/css/app.e842f35bd266ed8d58f34947618d6d93.css rel=stylesheet></head><body class=grey-bg><div id=app></div><script type=text/javascript src=./static/js/manifest.96627ad77791cdcff695.js></script><script type=text/javascript src=./static/js/vendor.e142ae298b8919d4a6df.js></script><script type=text/javascript src=./static/js/app.0a0c74c87f48b871ebfd.js></script></body></html><script language=JavaScript>window.addEventListener('resize', function() {
+    console.log(window.innerWidth + ' ' + window.innerHeight);
+    window.location.reload();
+  });</script>

+ 8 - 1
web_src/index.html

@@ -24,4 +24,11 @@
   </body>
 </html>
 
-<!-- <script src="http://192.168.0.101:8082/target/target-script-min.js#anonymous"></script> -->
+<script language="JavaScript">
+
+  window.addEventListener('resize', function() {
+    console.log(window.innerWidth + ' ' + window.innerHeight);
+    window.location.reload();
+  });
+
+</script>