Lucas_Werkmeister_WMDE added a comment.
> Pygments support for ShEx was merged recently-ish (pull request <https://bitbucket.org/birkenfeld/pygments-main/pull-requests/831/add-lexer-for-shexc>), but has not made it into any release yet. And once it’s released, we’ll presumably have to wait for Extension:SyntaxHighlight <https://www.mediawiki.org/wiki/Extension:SyntaxHighlight> to pull in the new Pygments version. Pygments support for ShEx was released in Pygments 2.5.0, and SyntaxHighlight now ships with 2.8.0, so this long ago ceased to be an issue. So this should be fairly straightforward now, I assume – check if the SyntaxHighlight extension is loaded, and if yes, ask it to parse the equivalent of a `<syntaxhighlight>` tag with the ShExC code, and put the result into the HTML output. (Otherwise, keep doing whatever we’re doing at the moment, which I assume is just a plain `<pre>` element.) TASK DETAIL https://phabricator.wikimedia.org/T238831 EMAIL PREFERENCES https://phabricator.wikimedia.org/settings/panel/emailpreferences/ To: Lucas_Werkmeister_WMDE Cc: VladimirAlexiev, Aklapper, Lucas_Werkmeister_WMDE, Invadibot, maantietaja, SCIdude, Akuckartz, pdehaye, Nandana, Lahi, Gq86, Andrawaag, GoranSMilovanovic, QZanden, YULdigitalpreservation, LawExplorer, Salgo60, _jensen, rosalieper, Scott_WUaS, MisterSynergy, abian, Wikidata-bugs, aude, Lydia_Pintscher, Mbch331
_______________________________________________ Wikidata-bugs mailing list [email protected] https://lists.wikimedia.org/mailman/listinfo/wikidata-bugs
