Skip to content

feat: lightweight math renderer - #75

Merged
flying-sheep merged 7 commits into
mainfrom
math-core
Oct 27, 2026
Merged

flying-sheep merged 7 commits into
mainfrom
math-core

Conversation

@flying-sheep

@flying-sheep flying-sheep commented Oct 23, 2026 •

Copy link
Copy Markdown
Member

The default MathJax works at runtime and therefore runs heavy JS just to reflow the page.

KaTeX (like used in our cookiecutter) needs node at build time to not do that.

I just found math-core which is nice, quite complete, and fully build time.

Examples: https://scverse-doc--75.org.readthedocs.build/en/75/api/math_core.html

PS: switching docs pages to rST because of executablebooks/MyST-Parser#771

@read-the-docs-community

read-the-docs-community Bot commented Oct 23, 2026 •

Copy link
Copy Markdown

Documentation build overview

📚 scverse-doc | 🛠️ Build #35436427 | 📁 Comparing d63b3e5 against latest (7e617f7)

  🔍 Preview build  

9 files changed · + 1 added · ± 8 modified

+ Added

± Modified

@codecov

codecov Bot commented Oct 23, 2026 •

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 100.00%. Comparing base (ddfb6f4) to head (d63b3e5).

Additional details and impacted files
@@            Coverage Diff            @@
##              main       #75   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files           11        12    +1     
  Lines          638       688   +50     
=========================================
+ Hits           638       688   +50     
Files with missing lines Coverage Δ
src/scverse_doc/__init__.py 100.00% <100.00%> (ø)
src/scverse_doc/math_core.py 100.00% <100.00%> (ø)
src/scverse_doc/registry.py 100.00% <ø> (ø)
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@flying-sheep
flying-sheep requested a review from Zethson October 23, 2026 09:45
@flying-sheep
flying-sheep merged commit 0eaabce into main Oct 27, 2026
16 checks passed
@flying-sheep
flying-sheep deleted the math-core branch October 27, 2026 08:34

@Zethson Zethson left a comment •

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I had deliberately not reviewed this one as it switches back to rst. This is an open discussion.
I understand that changes here aren't necessarily developer facing in packages but I'd be happy to have things consistent (always my pet peeve)

@flying-sheep

flying-sheep commented Oct 27, 2026 •

Copy link
Copy Markdown
Member Author

The switching to rST is purely for technical reasons because of MyST bugs (see linked issue). Whenever {eval-rst} exists, MyST messes things up, so I converted all the stub pages that are just a header and a {eval-rst} directive to rST (removing two lines and otherwise keeping things the same)

I encountered the bug in this PR so I changed things in this PR. Happy to change things back once they fix things or we find another solution, but until then, this is necessary.

The only ways to have everything consistent have always been 1. having everything rST because of docstrings or 2. not using autodoc.

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.

2 participants