Browse Source

//redirect the TS with the hash of the saved playground

DEV-UNITY-6\Utilisateur 6 năm trước cách đây
mục cha
commit
db414bdb38
1 tập tin đã thay đổi với 5 bổ sung1 xóa
  1. 5 1
      Playground/ts.html

+ 5 - 1
Playground/ts.html

@@ -1,4 +1,8 @@
 <script>
     localStorage.setItem("bjs-playground-scriptLanguage", "TS");
-    window.location = "./";
+
+    var parseURL = window.location.href.split("ts.html");
+    var hash = parseURL[parseURL.length - 1];
+
+    window.location = "./"+hash;
 </script>