Closed waldyrious closed 2 years ago
It's not a bug in the playground, but a bug in the parser. You can reproduce it with plain djot.
Ah, thanks for the clarification. Can you move this issue to the main repository, or should I report a new issue there?
Fixed in 4246252b16a988ad9473b810c10a2036d768cdb6
That was fast! :smile:
For convenience, here's a linked reference to the commmit: https://github.com/jgm/djot/commit/4246252b16a988ad9473b810c10a2036d768cdb6
I tried entering a code block by typing the delimiters first:
and then adding the content within:
test
...but this broke the playground, which became unresponsive. The console error is this:
Click to expand
``` Uncaught (in promise) Error: ./djot/html.lua:63: bad argument #1 to 'find' (string expected, got nil) assertOk https://djot.net/playground/assets/index.3c860766.js:1 b https://djot.net/playground/assets/index.3c860766.js:1 p https://djot.net/playground/assets/index.3c860766.js:43 p https://djot.net/playground/assets/index.3c860766.js:43 er https://djot.net/playground/assets/index.3c860766.js:1 p https://djot.net/playground/assets/index.3c860766.js:45 Qn https://djot.net/playground/assets/index.3c860766.js:1 Vt https://djot.net/playground/assets/index.3c860766.js:1 promise callback*Kn https://djot.net/playground/assets/index.3c860766.js:1 nr https://djot.net/playground/assets/index.3c860766.js:1 ctx https://djot.net/playground/assets/index.3c860766.js:1 B https://djot.net/playground/assets/index.3c860766.js:60 dt https://djot.net/playground/assets/index.3c860766.js:1 m https://djot.net/playground/assets/index.3c860766.js:45 bn https://djot.net/playground/assets/index.3c860766.js:1 vn https://djot.net/playground/assets/index.3c860766.js:1 Er https://djot.net/playground/assets/index.3c860766.js:60Note: this doesn't happen if I type the code block line by line (opening delimiters, content, closing delimiters)