aboutsummaryrefslogtreecommitdiffstats
path: root/development/index.html
diff options
context:
space:
mode:
authorkumavis <aaron@kumavis.me>2017-09-30 02:50:24 +0800
committerkumavis <aaron@kumavis.me>2017-09-30 02:50:24 +0800
commit19e7adad1920ac506b3ef5c639ec110a2615bd7c (patch)
tree8d696945a0a33eb7b85195b8ac04f07c2e574cdf /development/index.html
parentcdf41c28573822c7c4d50efe7dfa34a062825d7f (diff)
downloadtangerine-wallet-browser-19e7adad1920ac506b3ef5c639ec110a2615bd7c.tar
tangerine-wallet-browser-19e7adad1920ac506b3ef5c639ec110a2615bd7c.tar.gz
tangerine-wallet-browser-19e7adad1920ac506b3ef5c639ec110a2615bd7c.tar.bz2
tangerine-wallet-browser-19e7adad1920ac506b3ef5c639ec110a2615bd7c.tar.lz
tangerine-wallet-browser-19e7adad1920ac506b3ef5c639ec110a2615bd7c.tar.xz
tangerine-wallet-browser-19e7adad1920ac506b3ef5c639ec110a2615bd7c.tar.zst
tangerine-wallet-browser-19e7adad1920ac506b3ef5c639ec110a2615bd7c.zip
development - fix ui dev
Diffstat (limited to 'development/index.html')
-rw-r--r--development/index.html84
1 files changed, 40 insertions, 44 deletions
diff --git a/development/index.html b/development/index.html
index a0814cb55..e5a027447 100644
--- a/development/index.html
+++ b/development/index.html
@@ -3,62 +3,58 @@
<head>
<meta charset="utf-8">
<title>MetaMask</title>
-
</head>
<body>
-
- <!-- app content -->
- <div id="app-content" style="height: 100%"></div>
<script src="./bundle.js" type="text/javascript" charset="utf-8"></script>
+
+ <style>
+ html, body, #test-container, .super-dev-container {
+ height: 100%;
+ width: 100%;
+ position: relative;
+ background: white;
+ }
+ #app-content {
+ background: #F7F7F7;
+ }
+ </style>
- </body>
+ <script>
+ liveReloadCode(Date.now(), 300)
+ function liveReloadCode(lastUpdate, updateRate) {
+ setTimeout(iter, updateRate)
-<style>
-html, body, #test-container, .super-dev-container {
- height: 100%;
- width: 100%;
- position: relative;
- background: white;
-}
-#app-content {
- background: #F7F7F7;
-}
-</style>
+ function iter() {
+ var xhr = new XMLHttpRequest()
-<script>
-liveReloadCode(Date.now(), 300)
-function liveReloadCode(lastUpdate, updateRate) {
- setTimeout(iter, updateRate)
+ xhr.open('GET', '/-/live-reload')
+ xhr.onreadystatechange = function() {
+ if(xhr.readyState !== 4) {
+ return
+ }
- function iter() {
- var xhr = new XMLHttpRequest()
+ try {
+ var change = JSON.parse(xhr.responseText).lastUpdate
- xhr.open('GET', '/-/live-reload')
- xhr.onreadystatechange = function() {
- if(xhr.readyState !== 4) {
- return
- }
+ if(lastUpdate < change) {
+ return reload()
+ }
+ } catch(err) {
+ }
- try {
- var change = JSON.parse(xhr.responseText).lastUpdate
+ xhr =
+ xhr.onreadystatechange = null
+ setTimeout(iter, updateRate)
+ }
- if(lastUpdate < change) {
- return reload()
+ xhr.send(null)
}
- } catch(err) {
}
- xhr =
- xhr.onreadystatechange = null
- setTimeout(iter, updateRate)
- }
-
- xhr.send(null)
- }
-}
+ function reload() {
+ window.location.reload()
+ }
+ </script>
-function reload() {
- window.location.reload()
-}
- </script>
+ </body>
</html>