Repository: shikijs/shiki
Pull request #872 (2024-12-21 01:56:10)

feat(engine-js): update deps, support new languages
Bumps `oniguruma-to-es` to [0.8.1](https://github.com/slevithan/oniguruma-to-es/releases), moving Markdown and PO from Mismatched to Supported in the JS engine report.

netlify[bot]: ### <span aria-hidden="true">👷</span> Deploy Preview for *shiki-next* processing.


|  Name | Link |
|:-:|------------------------|
|<span aria-hidden="true">🔨</span> Latest commit | d7a0c2cfb5e0363ceec45a13a71a6c1a963ff6be |
|<span aria-hidden="true">🔍</span> Latest deploy log | https://app.netlify.com/sites/shiki-next/deploys/6766203c8dda380008b59b7c |
netlify[bot]: ### <span aria-hidden="true">👷</span> Deploy Preview for *shiki-matsu* processing.


|  Name | Link |
|:-:|------------------------|
|<span aria-hidden="true">🔨</span> Latest commit | d7a0c2cfb5e0363ceec45a13a71a6c1a963ff6be |
|<span aria-hidden="true">🔍</span> Latest deploy log | https://app.netlify.com/sites/shiki-matsu/deploys/6766203c9a68dd000896937b |

Patch:
diff --git a/docs/packages/next.md b/docs/packages/next.md
index 0de6def7..66692135 100644
--- a/docs/packages/next.md
+++ b/docs/packages/next.md
@@ -125,7 +125,7 @@ In your `codeblock.tsx`:
 
 ```tsx
 'use client'
-import { useLayoutEffect, useState } from 'react'
+import { JSX, useLayoutEffect, useState } from 'react'
 import { highlight } from './shared'
 
 export function CodeBlock({ initial }: { initial?: JSX.Element }) {
diff --git a/docs/references/engine-js-compat.md b/docs/references/engine-js-compat.md
index f1b29548..a4576d54 100644
--- a/docs/references/engine-js-compat.md
+++ b/docs/references/engine-js-compat.md
@@ -2,9 +2,9 @@
 
 Compatibility reference of all built-in grammars with the [JavaScript RegExp engine](/guide/regex-engines#javascript-regexp-engine).
 
-> Generated on Thursday, December 19, 2024
+> Generated on Saturday, December 21, 2024
 >
-> Version `1.24.2`
+> Version `1.24.3`
 >
 > Runtime: Node.js v22.11.0
 
@@ -13,8 +13,8 @@ Compatibility reference of all built-in grammars with the [JavaScript RegExp eng
 |                 |                       Count |
 | :-------------- | --------------------------: |
 | Total Languages |                         218 |
-| Supported       | [206](#supported-languages) |
-| Mismatched      |  [6](#mismatched-languages) |
+| Supported       | [208](#supported-languages) |
+| Mismatched      |  [4](#mismatched-languages) |
 | Unsupported     | [6](#unsupported-languages) |
 
 ## Supported Languages
@@ -132,6 +132,7 @@ In some edge cases, it's not guaranteed that the highlighting will be 100% the s
 | lua                | ✅ OK           |               278 |               - |      |
 | luau               | ✅ OK           |                88 |               - |      |
 | make               | ✅ OK           |                51 |               - |      |
+| markdown           | ✅ OK           |               118 |               - |      |
 | marko              | ✅ OK           |               926 |               - |      |
 | matlab             | ✅ OK           |                88 |               - |      |
 | mdc                | ✅ OK           |               783 |               - |      |
@@ -152,6 +153,7 @@ In some edge cases, it's not guaranteed that the highlighting will be 100% the s
 | perl               | ✅ OK           |               941 |               - |      |
 | php                | ✅ OK           |              1131 |               - |      |
 | plsql              | ✅ OK           |                45 |               - |      |
+| po                 | ✅ OK           |                23 |               - |      |
 | postcss            | ✅ OK           |                49 |               - |      |
 | powerquery         | ✅ OK           |                30 |               - |      |
 | powershell         | ✅ OK           |                88 |               - |      |
@@ -242,14 +244,12 @@ In some edge cases, it's not guaranteed that the highlighting will be 100% the s
 
 Languages that do not throw with the JavaScript RegExp engine, but will produce different results than the WASM engine. Please use with caution.
 
-| Language | Highlight Match                                                               | Patterns Parsable | Patterns Failed | Diff |
-| -------- | :---------------------------------------------------------------------------- | ----------------: | --------------: | ---: |
-| apex     | [🚧 Mismatch](https://textmate-grammars-themes.netlify.app/?grammar=apex)     |               187 |               - |   33 |
-| cpp      | [🚧 Mismatch](https://textmate-grammars-themes.netlify.app/?grammar=cpp)      |               512 |               - |    8 |
-| kusto    | [🚧 Mismatch](https://textmate-grammars-themes.netlify.app/?grammar=kusto)    |                60 |               - |   40 |
-| markdown | [🚧 Mismatch](https://textmate-grammars-themes.netlify.app/?grammar=markdown) |               118 |               - |  100 |
-| nginx    | [🚧 Mismatch](https://textmate-grammars-themes.netlify.app/?grammar=nginx)    |               378 |               - |  122 |
-| po       | [🚧 Mismatch](https://textmate-grammars-themes.netlify.app/?grammar=po)       |                23 |               - |  114 |
+| Language | Highlight Match                                                            | Patterns Parsable | Patterns Failed | Diff |
+| -------- | :------------------------------------------------------------------------- | ----------------: | --------------: | ---: |
+| apex     | [🚧 Mismatch](https://textmate-grammars-themes.netlify.app/?grammar=apex)  |               187 |               - |   33 |
+| cpp      | [🚧 Mismatch](https://textmate-grammars-themes.netlify.app/?grammar=cpp)   |               512 |               - |    8 |
+| kusto    | [🚧 Mismatch](https://textmate-grammars-themes.netlify.app/?grammar=kusto) |                60 |               - |   40 |
+| nginx    | [🚧 Mismatch](https://textmate-grammars-themes.netlify.app/?grammar=nginx) |               378 |               - |  122 |
 
 ## Unsupported Languages
 
diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml
index a902e125..bacec026 100644
--- a/pnpm-lock.yaml
+++ b/pnpm-lock.yaml
@@ -142,8 +142,8 @@ catalogs:
       specifier: ^1.1.4
       version: 1.1.4
     oniguruma-to-es:
-      specifier: 0.8.0
-      version: 0.8.0
+      specifier: 0.8.1
+      version: 0.8.1
     picocolors:
       specifier: ^1.1.1
       version: 1.1.1
@@ -555,7 +555,7 @@ importers:
         version: 9.3.1
       oniguruma-to-es:
         specifier: 'catalog:'
-        version: 0.8.0
+        version: 0.8.1
 
   packages/engine-oniguruma:
     dependencies:
@@ -4047,8 +4047,8 @@ packages:
     resolution: {integrity: sha512-VXJjc87FScF88uafS3JllDgvAm+c/Slfz06lorj2uAY34rlUu0Nt+v8wreiImcrgAjjIHp1rXpTDlLOGw29WwQ==}
     engines: {node: '>=18'}
 
-  oniguruma-to-es@0.8.0:
-    resolution: {integrity: sha512-rY+/a6b+uCgoYIL9itjY0x99UUDHXmGaw7Jjk5ZvM/3cxDJifyxFr/Zm4tTmF6Tre18gAakJo7AzhKUeMNLgHA==}
+  oniguruma-to-es@0.8.1:
+    resolution: {integrity: sha512-dekySTEvCxCj0IgKcA2uUCO/e4ArsqpucDPcX26w9ajx+DvMWLc5eZeJaRQkd7oC/+rwif5gnT900tA34uN9Zw==}
 
   optionator@0.9.4:
     resolution: {integrity: sha512-6IpQ7mKUxRcZNLIObR0hz7lxsapSSIYNZJwXPGeF0mTVqGKFIXj1DQcMoT22S3ROcLyY/rz0PWaWZ9ayWmad9g==}
@@ -9099,7 +9099,7 @@ snapshots:
     dependencies:
       mimic-function: 5.0.1
 
-  oniguruma-to-es@0.8.0:
+  oniguruma-to-es@0.8.1:
     dependencies:
       emoji-regex-xs: 1.0.0
       regex: 5.0.2
diff --git a/pnpm-workspace.yaml b/pnpm-workspace.yaml
index 66b8bcef..2b547e83 100644
--- a/pnpm-workspace.yaml
+++ b/pnpm-workspace.yaml
@@ -54,7 +54,7 @@ catalog:
   monaco-editor-core: ^0.52.2
   ofetch: ^1.4.1
   ohash: ^1.1.4
-  oniguruma-to-es: 0.8.0
+  oniguruma-to-es: 0.8.1
   picocolors: ^1.1.1
   pinia: ^2.3.0
   pnpm: ^9.15.0


Test patch:
diff --git a/packages/engine-javascript/test/__records__/markdown.js.json b/packages/engine-javascript/test/__records__/markdown.js.json
index 916e2e62..859f372c 100644
--- a/packages/engine-javascript/test/__records__/markdown.js.json
+++ b/packages/engine-javascript/test/__records__/markdown.js.json
@@ -886,13 +886,13 @@
       "index": 11,
       "captureIndices": [
         {
-          "start": 0,
-          "end": 0,
+          "start": 4,
+          "end": 4,
           "length": 0
         },
         {
-          "start": 0,
-          "end": 0,
+          "start": 4,
+          "end": 4,
           "length": 0
         }
       ]
@@ -1005,28 +1005,28 @@
       "index": 3,
       "captureIndices": [
         {
-          "start": 0,
-          "end": 2,
+          "start": 2,
+          "end": 4,
           "length": 2
         },
         {
-          "start": 0,
-          "end": 0,
+          "start": 2,
+          "end": 2,
           "length": 0
         },
         {
-          "start": 0,
-          "end": 0,
+          "start": 2,
+          "end": 2,
           "length": 0
         },
         {
-          "start": 0,
-          "end": 1,
+          "start": 2,
+          "end": 3,
           "length": 1
         },
         {
-          "start": 1,
-          "end": 2,
+          "start": 3,
+          "end": 4,
           "length": 1
         }
       ]
@@ -1051,40 +1051,53 @@
     ],
     "args": [
       "  * that one\n",
-      2,
+      4,
       0
     ],
     "result": {
-      "index": 3,
+      "index": 11,
       "captureIndices": [
         {
-          "start": 0,
-          "end": 2,
-          "length": 2
-        },
-        {
-          "start": 0,
-          "end": 0,
+          "start": 4,
+          "end": 4,
           "length": 0
         },
         {
-          "start": 0,
-          "end": 0,
+          "start": 4,
+          "end": 4,
           "length": 0
-        },
-        {
-          "start": 0,
-          "end": 1,
-          "length": 1
-        },
-        {
-          "start": 1,
-          "end": 2,
-          "length": 1
         }
       ]
     }
   },
+  {
+    "id": "3O5Mw8yMa3",
+    "patterns": [
+      "&(?!([a-zA-Z0-9]+|#\\d+|#x[0-9a-fA-F]+);)",
+      "<(?![a-zA-Z/?$!])",
+      "(?<open>(\\*\\*(?=\\w)|(?<!\\w)\\*\\*|(?<!\\w)\\b__))(?=\\S)(?=(<[^>]*+>|(?<raw>`+)([^`]|(?!(?<!`)\\k<raw>(?!`))`)*+\\k<raw>|\\\\[\\\\`*_{}\\[\\]()#.!+\\->]?+|\\[((?<square>[^\\[\\]\\\\]|\\\\.|\\[\\g<square>*+\\])*+\\](([ ]?\\[[^\\]]*+\\])|(\\([ \\t]*+<?(.*?)>?[ \\t]*+((?<title>['\"])(.*?)\\k<title>)?\\))))|(?!(?<=\\S)\\k<open>).)++(?<=\\S)(?=__\\b|\\*\\*)\\k<open>)",
+      "(?<open>(\\*(?=\\w)|(?<!\\w)\\*|(?<!\\w)\\b_))(?=\\S)(?=(<[^>]*+>|(?<raw>`+)([^`]|(?!(?<!`)\\k<raw>(?!`))`)*+\\k<raw>|\\\\[\\\\`*_{}\\[\\]()#.!+\\->]?+|\\[((?<square>[^\\[\\]\\\\]|\\\\.|\\[\\g<square>*+\\])*+\\](([ ]?\\[[^\\]]*+\\])|(\\([ \\t]*+<?(.*?)>?[ \\t]*+((?<title>['\"])(.*?)\\k<title>)?\\))))|\\k<open>\\k<open>|(?!(?<=\\S)\\k<open>).)++(?<=\\S)(?=_\\b|\\*)\\k<open>)",
+      "(`+)((?:[^`]|(?!(?<!`)\\1(?!`))`)*+)(\\1)",
+      "(?<!\\\\)(~{2,})((?:[^~]|(?!(?<![~\\\\])\\1(?!~))~)*+)(\\1)",
+      "\\\\[-`*_#+.!(){}\\[\\]\\\\>]",
+      "(!\\[)((?<square>[^\\[\\]\\\\]|\\\\.|\\[\\g<square>*+\\])*+)(\\])(\\()[ \\t]*((<)((?:\\\\[<>]|[^<>\\n])*)(>)|((?<url>(?>[^\\s()]+)|\\(\\g<url>*\\))*))[ \\t]*(?:((\\().+?(\\)))|((\").+?(\"))|((').+?(')))?\\s*(\\))",
+      "(!\\[)((?<square>[^\\[\\]\\\\]|\\\\.|\\[\\g<square>*+\\])*+)(\\])[ ]?(\\[)(.*?)(\\])",
+      "(<)((?:mailto:)?[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+@[a-zA-Z0-9-]+(?:\\.[a-zA-Z0-9-]+)*)(>)",
+      "(<)((?:https?|ftp)://.*?)(>)",
+      "(\\[)((?<square>[^\\[\\]\\\\]|\\\\.|\\[\\g<square>*+\\])*+)(\\])(\\()[ \\t]*((<)((?:\\\\[<>]|[^<>\\n])*)(>)|((?<url>(?>[^\\s()]+)|\\(\\g<url>*\\))*))[ \\t]*(?:((\\()[^()]*(\\)))|((\")[^\"]*(\"))|((')[^']*(')))?\\s*(\\))",
+      "(?<![\\]\\\\])(\\[)((?<square>[^\\[\\]\\\\]|\\\\.|\\[\\g<square>*+\\])*+)(\\])(\\[)([^\\]]*+)(\\])",
+      "(?<![\\]\\\\])(\\[)((?<square>[^\\[\\]\\\\]|\\\\.|\\[\\g<square>*+\\])*+)(\\])[ ]?(\\[)(\\])",
+      "(?<![\\]\\\\])(\\[)((?:[^\\s\\[\\]\\\\]|\\\\[\\[\\]])+?)((?<!\\\\)\\])",
+      "^(={3,})(?=[ \\t]*$\\n?)",
+      "^(-{3,})(?=[ \\t]*$\\n?)"
+    ],
+    "args": [
+      "  * that one\n",
+      4,
+      0
+    ],
+    "result": null
+  },
   {
     "id": "o849naoraG",
     "patterns": [
@@ -1164,28 +1177,28 @@
       "index": 3,
       "captureIndices": [
         {
-          "start": 0,
-          "end": 2,
+          "start": 2,
+          "end": 4,
           "length": 2
         },
         {
-          "start": 0,
-          "end": 0,
+          "start": 2,
+          "end": 2,
           "length": 0
         },
         {
-          "start": 0,
-          "end": 0,
+          "start": 2,
+          "end": 2,
           "length": 0
         },
         {
-          "start": 0,
-          "end": 1,
+          "start": 2,
+          "end": 3,
           "length": 1
         },
         {
-          "start": 1,
-          "end": 2,
+          "start": 3,
+          "end": 4,
           "length": 1
         }
       ]
@@ -1210,40 +1223,53 @@
     ],
     "args": [
       "  * the other one\n",
-      2,
+      4,
       0
     ],
     "result": {
-      "index": 3,
+      "index": 11,
       "captureIndices": [
         {
-          "start": 0,
-          "end": 2,
-          "length": 2
-        },
-        {
-          "start": 0,
-          "end": 0,
+          "start": 4,
+          "end": 4,
           "length": 0
         },
         {
-          "start": 0,
-          "end": 0,
+          "start": 4,
+          "end": 4,
           "length": 0
-        },
-        {
-          "start": 0,
-          "end": 1,
-          "length": 1
-        },
-        {
-          "start": 1,
-          "end": 2,
-          "length": 1
         }
       ]
     }
   },
+  {
+    "id": "3O5Mw8yMa3",
+    "patterns": [
+      "&(?!([a-zA-Z0-9]+|#\\d+|#x[0-9a-fA-F]+);)",
+      "<(?![a-zA-Z/?$!])",
+      "(?<open>(\\*\\*(?=\\w)|(?<!\\w)\\*\\*|(?<!\\w)\\b__))(?=\\S)(?=(<[^>]*+>|(?<raw>`+)([^`]|(?!(?<!`)\\k<raw>(?!`))`)*+\\k<raw>|\\\\[\\\\`*_{}\\[\\]()#.!+\\->]?+|\\[((?<square>[^\\[\\]\\\\]|\\\\.|\\[\\g<square>*+\\])*+\\](([ ]?\\[[^\\]]*+\\])|(\\([ \\t]*+<?(.*?)>?[ \\t]*+((?<title>['\"])(.*?)\\k<title>)?\\))))|(?!(?<=\\S)\\k<open>).)++(?<=\\S)(?=__\\b|\\*\\*)\\k<open>)",
+      "(?<open>(\\*(?=\\w)|(?<!\\w)\\*|(?<!\\w)\\b_))(?=\\S)(?=(<[^>]*+>|(?<raw>`+)([^`]|(?!(?<!`)\\k<raw>(?!`))`)*+\\k<raw>|\\\\[\\\\`*_{}\\[\\]()#.!+\\->]?+|\\[((?<square>[^\\[\\]\\\\]|\\\\.|\\[\\g<square>*+\\])*+\\](([ ]?\\[[^\\]]*+\\])|(\\([ \\t]*+<?(.*?)>?[ \\t]*+((?<title>['\"])(.*?)\\k<title>)?\\))))|\\k<open>\\k<open>|(?!(?<=\\S)\\k<open>).)++(?<=\\S)(?=_\\b|\\*)\\k<open>)",
+      "(`+)((?:[^`]|(?!(?<!`)\\1(?!`))`)*+)(\\1)",
+      "(?<!\\\\)(~{2,})((?:[^~]|(?!(?<![~\\\\])\\1(?!~))~)*+)(\\1)",
+      "\\\\[-`*_#+.!(){}\\[\\]\\\\>]",
+      "(!\\[)((?<square>[^\\[\\]\\\\]|\\\\.|\\[\\g<square>*+\\])*+)(\\])(\\()[ \\t]*((<)((?:\\\\[<>]|[^<>\\n])*)(>)|((?<url>(?>[^\\s()]+)|\\(\\g<url>*\\))*))[ \\t]*(?:((\\().+?(\\)))|((\").+?(\"))|((').+?(')))?\\s*(\\))",
+      "(!\\[)((?<square>[^\\[\\]\\\\]|\\\\.|\\[\\g<square>*+\\])*+)(\\])[ ]?(\\[)(.*?)(\\])",
+      "(<)((?:mailto:)?[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+@[a-zA-Z0-9-]+(?:\\.[a-zA-Z0-9-]+)*)(>)",
+      "(<)((?:https?|ftp)://.*?)(>)",
+      "(\\[)((?<square>[^\\[\\]\\\\]|\\\\.|\\[\\g<square>*+\\])*+)(\\])(\\()[ \\t]*((<)((?:\\\\[<>]|[^<>\\n])*)(>)|((?<url>(?>[^\\s()]+)|\\(\\g<url>*\\))*))[ \\t]*(?:((\\()[^()]*(\\)))|((\")[^\"]*(\"))|((')[^']*(')))?\\s*(\\))",
+      "(?<![\\]\\\\])(\\[)((?<square>[^\\[\\]\\\\]|\\\\.|\\[\\g<square>*+\\])*+)(\\])(\\[)([^\\]]*+)(\\])",
+      "(?<![\\]\\\\])(\\[)((?<square>[^\\[\\]\\\\]|\\\\.|\\[\\g<square>*+\\])*+)(\\])[ ]?(\\[)(\\])",
+      "(?<![\\]\\\\])(\\[)((?:[^\\s\\[\\]\\\\]|\\\\[\\[\\]])+?)((?<!\\\\)\\])",
+      "^(={3,})(?=[ \\t]*$\\n?)",
+      "^(-{3,})(?=[ \\t]*$\\n?)"
+    ],
+    "args": [
+      "  * the other one\n",
+      4,
+      0
+    ],
+    "result": null
+  },
   {
     "id": "o849naoraG",
     "patterns": [
@@ -1476,13 +1502,13 @@
       "index": 11,
       "captureIndices": [
         {
-          "start": 0,
-          "end": 0,
+          "start": 4,
+          "end": 4,
           "length": 0
         },
         {
-          "start": 0,
-          "end": 0,
+          "start": 4,
+          "end": 4,
           "length": 0
         }
       ]
@@ -1595,28 +1621,28 @@
       "index": 3,
       "captureIndices": [
         {
-          "start": 0,
-          "end": 2,
+          "start": 2,
+          "end": 4,
           "length": 2
         },
         {
-          "start": 0,
-          "end": 0,
+          "start": 2,
+          "end": 2,
           "length": 0
         },
         {
-          "start": 0,
-          "end": 0,
+          "start": 2,
+          "end": 2,
           "length": 0
         },
         {
-          "start": 0,
-          "end": 1,
+          "start": 2,
+          "end": 3,
           "length": 1
         },
         {
-          "start": 1,
-          "end": 2,
+          "start": 3,
+          "end": 4,
           "length": 1
         }
       ]
@@ -1641,40 +1667,53 @@
     ],
     "args": [
       "  * that one\n",
-      2,
+      4,
       0
     ],
     "result": {
-      "index": 3,
+      "index": 11,
       "captureIndices": [
         {
-          "start": 0,
-          "end": 2,
-          "length": 2
-        },
-        {
-          "start": 0,
-          "end": 0,
+          "start": 4,
+          "end": 4,
           "length": 0
         },
         {
-          "start": 0,
-          "end": 0,
+          "start": 4,
+          "end": 4,
           "length": 0
-        },
-        {
-          "start": 0,
-          "end": 1,
-          "length": 1
-        },
-        {
-          "start": 1,
-          "end": 2,
-          "length": 1
         }
       ]
     }
   },
+  {
+    "id": "3O5Mw8yMa3",
+    "patterns": [
+      "&(?!([a-zA-Z0-9]+|#\\d+|#x[0-9a-fA-F]+);)",
+      "<(?![a-zA-Z/?$!])",
+      "(?<open>(\\*\\*(?=\\w)|(?<!\\w)\\*\\*|(?<!\\w)\\b__))(?=\\S)(?=(<[^>]*+>|(?<raw>`+)([^`]|(?!(?<!`)\\k<raw>(?!`))`)*+\\k<raw>|\\\\[\\\\`*_{}\\[\\]()#.!+\\->]?+|\\[((?<square>[^\\[\\]\\\\]|\\\\.|\\[\\g<square>*+\\])*+\\](([ ]?\\[[^\\]]*+\\])|(\\([ \\t]*+<?(.*?)>?[ \\t]*+((?<title>['\"])(.*?)\\k<title>)?\\))))|(?!(?<=\\S)\\k<open>).)++(?<=\\S)(?=__\\b|\\*\\*)\\k<open>)",
+      "(?<open>(\\*(?=\\w)|(?<!\\w)\\*|(?<!\\w)\\b_))(?=\\S)(?=(<[^>]*+>|(?<raw>`+)([^`]|(?!(?<!`)\\k<raw>(?!`))`)*+\\k<raw>|\\\\[\\\\`*_{}\\[\\]()#.!+\\->]?+|\\[((?<square>[^\\[\\]\\\\]|\\\\.|\\[\\g<square>*+\\])*+\\](([ ]?\\[[^\\]]*+\\])|(\\([ \\t]*+<?(.*?)>?[ \\t]*+((?<title>['\"])(.*?)\\k<title>)?\\))))|\\k<open>\\k<open>|(?!(?<=\\S)\\k<open>).)++(?<=\\S)(?=_\\b|\\*)\\k<open>)",
+      "(`+)((?:[^`]|(?!(?<!`)\\1(?!`))`)*+)(\\1)",
+      "(?<!\\\\)(~{2,})((?:[^~]|(?!(?<![~\\\\])\\1(?!~))~)*+)(\\1)",
+      "\\\\[-`*_#+.!(){}\\[\\]\\\\>]",
+      "(!\\[)((?<square>[^\\[\\]\\\\]|\\\\.|\\[\\g<square>*+\\])*+)(\\])(\\()[ \\t]*((<)((?:\\\\[<>]|[^<>\\n])*)(>)|((?<url>(?>[^\\s()]+)|\\(\\g<url>*\\))*))[ \\t]*(?:((\\().+?(\\)))|((\").+?(\"))|((').+?(')))?\\s*(\\))",
+      "(!\\[)((?<square>[^\\[\\]\\\\]|\\\\.|\\[\\g<square>*+\\])*+)(\\])[ ]?(\\[)(.*?)(\\])",
+      "(<)((?:mailto:)?[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+@[a-zA-Z0-9-]+(?:\\.[a-zA-Z0-9-]+)*)(>)",
+      "(<)((?:https?|ftp)://.*?)(>)",
+      "(\\[)((?<square>[^\\[\\]\\\\]|\\\\.|\\[\\g<square>*+\\])*+)(\\])(\\()[ \\t]*((<)((?:\\\\[<>]|[^<>\\n])*)(>)|((?<url>(?>[^\\s()]+)|\\(\\g<url>*\\))*))[ \\t]*(?:((\\()[^()]*(\\)))|((\")[^\"]*(\"))|((')[^']*(')))?\\s*(\\))",
+      "(?<![\\]\\\\])(\\[)((?<square>[^\\[\\]\\\\]|\\\\.|\\[\\g<square>*+\\])*+)(\\])(\\[)([^\\]]*+)(\\])",
+      "(?<![\\]\\\\])(\\[)((?<square>[^\\[\\]\\\\]|\\\\.|\\[\\g<square>*+\\])*+)(\\])[ ]?(\\[)(\\])",
+      "(?<![\\]\\\\])(\\[)((?:[^\\s\\[\\]\\\\]|\\\\[\\[\\]])+?)((?<!\\\\)\\])",
+      "^(={3,})(?=[ \\t]*$\\n?)",
+      "^(-{3,})(?=[ \\t]*$\\n?)"
+    ],
+    "args": [
+      "  * that one\n",
+      4,
+      0
+    ],
+    "result": null
+  },
   {
     "id": "o849naoraG",
     "patterns": [
@@ -1754,28 +1793,28 @@
       "index": 3,
       "captureIndices": [
         {
-          "start": 0,
-          "end": 2,
+          "start": 2,
+          "end": 4,
           "length": 2
         },
         {
-          "start": 0,
-          "end": 0,
+          "start": 2,
+          "end": 2,
           "length": 0
         },
         {
-          "start": 0,
-          "end": 0,
+          "start": 2,
+          "end": 2,
           "length": 0
         },
         {
-          "start": 0,
-          "end": 1,
+          "start": 2,
+          "end": 3,
           "length": 1
         },
         {
-          "start": 1,
-          "end": 2,
+          "start": 3,
+          "end": 4,
           "length": 1
         }
       ]
@@ -1800,40 +1839,53 @@
     ],
     "args": [
       "  * the other one\n",
-      2,
+      4,
       0
     ],
     "result": {
-      "index": 3,
+      "index": 11,
       "captureIndices": [
         {
-          "start": 0,
-          "end": 2,
-          "length": 2
-        },
-        {
-          "start": 0,
-          "end": 0,
+          "start": 4,
+          "end": 4,
           "length": 0
         },
         {
-          "start": 0,
-          "end": 0,
+          "start": 4,
+          "end": 4,
           "length": 0
-        },
-        {
-          "start": 0,
-          "end": 1,
-          "length": 1
-        },
-        {
-          "start": 1,
-          "end": 2,
-          "length": 1
         }
       ]
     }
   },
+  {
+    "id": "3O5Mw8yMa3",
+    "patterns": [
+      "&(?!([a-zA-Z0-9]+|#\\d+|#x[0-9a-fA-F]+);)",
+      "<(?![a-zA-Z/?$!])",
+      "(?<open>(\\*\\*(?=\\w)|(?<!\\w)\\*\\*|(?<!\\w)\\b__))(?=\\S)(?=(<[^>]*+>|(?<raw>`+)([^`]|(?!(?<!`)\\k<raw>(?!`))`)*+\\k<raw>|\\\\[\\\\`*_{}\\[\\]()#.!+\\->]?+|\\[((?<square>[^\\[\\]\\\\]|\\\\.|\\[\\g<square>*+\\])*+\\](([ ]?\\[[^\\]]*+\\])|(\\([ \\t]*+<?(.*?)>?[ \\t]*+((?<title>['\"])(.*?)\\k<title>)?\\))))|(?!(?<=\\S)\\k<open>).)++(?<=\\S)(?=__\\b|\\*\\*)\\k<open>)",
+      "(?<open>(\\*(?=\\w)|(?<!\\w)\\*|(?<!\\w)\\b_))(?=\\S)(?=(<[^>]*+>|(?<raw>`+)([^`]|(?!(?<!`)\\k<raw>(?!`))`)*+\\k<raw>|\\\\[\\\\`*_{}\\[\\]()#.!+\\->]?+|\\[((?<square>[^\\[\\]\\\\]|\\\\.|\\[\\g<square>*+\\])*+\\](([ ]?\\[[^\\]]*+\\])|(\\([ \\t]*+<?(.*?)>?[ \\t]*+((?<title>['\"])(.*?)\\k<title>)?\\))))|\\k<open>\\k<open>|(?!(?<=\\S)\\k<open>).)++(?<=\\S)(?=_\\b|\\*)\\k<open>)",
+      "(`+)((?:[^`]|(?!(?<!`)\\1(?!`))`)*+)(\\1)",
+      "(?<!\\\\)(~{2,})((?:[^~]|(?!(?<![~\\\\])\\1(?!~))~)*+)(\\1)",
+      "\\\\[-`*_#+.!(){}\\[\\]\\\\>]",
+      "(!\\[)((?<square>[^\\[\\]\\\\]|\\\\.|\\[\\g<square>*+\\])*+)(\\])(\\()[ \\t]*((<)((?:\\\\[<>]|[^<>\\n])*)(>)|((?<url>(?>[^\\s()]+)|\\(\\g<url>*\\))*))[ \\t]*(?:((\\().+?(\\)))|((\").+?(\"))|((').+?(')))?\\s*(\\))",
+      "(!\\[)((?<square>[^\\[\\]\\\\]|\\\\.|\\[\\g<square>*+\\])*+)(\\])[ ]?(\\[)(.*?)(\\])",
+      "(<)((?:mailto:)?[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+@[a-zA-Z0-9-]+(?:\\.[a-zA-Z0-9-]+)*)(>)",
+      "(<)((?:https?|ftp)://.*?)(>)",
+      "(\\[)((?<square>[^\\[\\]\\\\]|\\\\.|\\[\\g<square>*+\\])*+)(\\])(\\()[ \\t]*((<)((?:\\\\[<>]|[^<>\\n])*)(>)|((?<url>(?>[^\\s()]+)|\\(\\g<url>*\\))*))[ \\t]*(?:((\\()[^()]*(\\)))|((\")[^\"]*(\"))|((')[^']*(')))?\\s*(\\))",
+      "(?<![\\]\\\\])(\\[)((?<square>[^\\[\\]\\\\]|\\\\.|\\[\\g<square>*+\\])*+)(\\])(\\[)([^\\]]*+)(\\])",
+      "(?<![\\]\\\\])(\\[)((?<square>[^\\[\\]\\\\]|\\\\.|\\[\\g<square>*+\\])*+)(\\])[ ]?(\\[)(\\])",
+      "(?<![\\]\\\\])(\\[)((?:[^\\s\\[\\]\\\\]|\\\\[\\[\\]])+?)((?<!\\\\)\\])",
+      "^(={3,})(?=[ \\t]*$\\n?)",
+      "^(-{3,})(?=[ \\t]*$\\n?)"
+    ],
+    "args": [
+      "  * the other one\n",
+      4,
+      0
+    ],
+    "result": null
+  },
   {
     "id": "o849naoraG",
     "patterns": [
diff --git a/packages/engine-javascript/test/verify.test.ts b/packages/engine-javascript/test/verify.test.ts
index 224247c3..dd59ab40 100644
--- a/packages/engine-javascript/test/verify.test.ts
+++ b/packages/engine-javascript/test/verify.test.ts
@@ -19,10 +19,6 @@ describe('verify', async () => {
     // Some token positions are off in this record
     const name = basename(file, '.wasm.json')
 
-    // TODO: markdown support is still problematic
-    if (name === 'markdown')
-      continue
-
     describe(`record: ${name}`, async () => {
       const executions = JSON.parse(await fs.readFile(file, 'utf-8')) as Execution[]
       let i = 0