Skip to content

Replace an incomplete Odin grammar implementation - #4542

Open
marianpekar wants to merge 3 commits into
highlightjs:mainfrom
marianpekar:main
Open

marianpekar wants to merge 3 commits into
highlightjs:mainfrom
marianpekar:main

Conversation

@marianpekar

@marianpekar marianpekar commented Sep 13, 2026

Copy link
Copy Markdown
Contributor

A couple of months ago, I implemented Odin grammar support, but I was told to submit it as a third-party support package because submissions for new languages were no longer accepted. So I did (d301848)

Today, I found out that a PR from someone else to core was accepted, replacing my third-party package with a grammar implementation that isn't even complete (16d804c)

I've put a lot more effort into my implementation and it also includes complete markup test coverage. Since submissions to core are open again (I assume), I reviewed my original package (https://www.npmjs.com/package/highlightjs-odinlang), added a few missing built-ins, fixed a few minor issues, and prepared this PR.

I also write blog posts on my blog at https://marianpekar.com/, where I use highlighting for Odin extensively. This means I constantly test the implementation in production, and whenever I notice something is missing or Odin introduces something new that isn't covered, I'm ready to extend the implementation.

In other words, I'm personally invested in providing long-term support for this implementation because I'm effectively "my own customer."

@github-actions

Copy link
Copy Markdown

Build Size Report

Changes to minified artifacts in /build, after gzip compression.

4 files changed

Total change +1.24 KB

View Changes
file base pr diff
es/core.min.js 8.16 KB 8.16 KB +1 B
es/highlight.min.js 8.16 KB 8.16 KB +1 B
es/languages/odin.min.js 1.14 KB 1.75 KB +616 B
languages/odin.min.js 1.14 KB 1.76 KB +618 B

@github-actions

Copy link
Copy Markdown

Build Size Report

Changes to minified artifacts in /build, after gzip compression.

4 files changed

Total change +1.26 KB

View Changes
file base pr diff
es/core.min.js 8.16 KB 8.16 KB +1 B
es/highlight.min.js 8.16 KB 8.16 KB +1 B
es/languages/odin.min.js 1.14 KB 1.77 KB +629 B
languages/odin.min.js 1.14 KB 1.77 KB +630 B

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant