chore!: upgrade mdex to 0.13 - #185
Conversation
|
Note that this builds on #184 (which is why there are two commits). |
If a Tableau blog uses MDEx syntax highlighting, the latest version of
MDEx has breaking changes to how syntax highlighting works and your blog
configuration must be modified for it to continue working.
There are two supported syntax highlighters: Lumis (tree-sitter) and
Syntect (Sublime Text grammars). Tableau includes the Lumis syntax
highlighter package, but it is not fully configured without modification
to the blog `config/config.exs` for selecting the appropriate syntax
highlighting NIF:
```elixir
config :mdex_native, syntax_highlighter: :lumis
config :mdex_native, syntax_highlighter: :syntect
```
The MDEx options configuration must also be updated:
```diff
render: [unsafe: true],
syntax_highlight: [
- formatter: {:html_inline, theme: "neovim_dark"}
+ engine: :lumis,
+ opts: [formatter: {:html_inline, theme: "neovim_dark"}]
],
plugins: [MDExGFM]
```
More details for each syntax highlighter can be found at
https://mdex.hexdocs.pm/lumis.html or
https://mdex.hexdocs.pm/syntect.html.
|
Thanks, this looks straightforward. I'm going to try this branch on my personal blog before merging. Note to self: update the tableau_new mix archive as well. |
|
I think the biggest trick is going to be making sure that the new version's release notes are clear on what needs to be done because it's not quite a routine release. I haven't been able to get my latest blog published, but that's an infra issue on my end not a Tableau problem where I was using the git version yesterday for everything. |
|
Hello! Is there anything I can do to help get this merged? I see 1 |
|
If you could try this branch against your own sight and confirm all the upgrade instructions work and make any corrections needed it would help. Thanks! |


If a Tableau blog uses MDEx syntax highlighting, the latest version of MDEx has breaking changes to how syntax highlighting works and your blog configuration must be modified for it to continue working.
There are two supported syntax highlighters: Lumis (tree-sitter) and Syntect (Sublime Text grammars). Tableau includes the Lumis syntax highlighter package, but it is not fully configured without modification to the blog
config/config.exsfor selecting the appropriate syntax highlighting NIF:The MDEx options configuration must also be updated:
render: [unsafe: true], syntax_highlight: [ - formatter: {:html_inline, theme: "neovim_dark"} + engine: :lumis, + opts: [formatter: {:html_inline, theme: "neovim_dark"}] ], plugins: [MDExGFM]More details for each syntax highlighter can be found at https://mdex.hexdocs.pm/lumis.html or https://mdex.hexdocs.pm/syntect.html.