Updated polyscript wth latest MicroPython (#2454)

This commit is contained in:
Andrea Giammarchi
2026-02-25 20:53:48 +01:00
committed by GitHub
parent e97696710a
commit 98011af6e8
3 changed files with 16 additions and 24 deletions

View File

@@ -20,7 +20,7 @@
symbol = js.Symbol.iterator
if js.getSymbol(symbol, []) and js.hasSymbol(symbol, []) and js.hasIterator([]):
if js.getSymbol(symbol, []) != None and js.hasSymbol(symbol, []) and js.hasIterator([]):
js.document.documentElement.classList.add("main")
</script>
<script type="mpy" worker>
@@ -29,7 +29,7 @@
symbol = js.Symbol.iterator
if window.getSymbol(symbol, []) and window.hasSymbol(symbol, []) and window.hasIterator([]):
if window.getSymbol(symbol, []) != None and window.hasSymbol(symbol, []) and window.hasIterator([]):
window.document.documentElement.classList.add("worker")
</script>
</head>