Skip to content

Implement suggested workaround for erroneous extension loading with CHTML renderer. #2736

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged

Conversation

drgrice1
Copy link
Member

@drgrice1 drgrice1 commented Jun 3, 2025

This is an alternate for #2734, and implements the workaround suggested by @dpvc in mathjax/MathJax#3370 (comment).

We just need to decide which approach is best.

@dpvc
Copy link
Member

dpvc commented Jun 3, 2025

You should probably note that if you move to v4, you will need to remove that code. Or you could put it in an if-then that checks the version of MathJax before making the changes.

…HTML renderer.

This is an alternate for openwebwork#2734, and implements the workaround suggested
by @dpvc in mathjax/MathJax#3370 (comment).
@drgrice1 drgrice1 force-pushed the mathjax-chtml-issue-fix branch from 773323a to c4ef16d Compare June 3, 2025 20:37
@drgrice1
Copy link
Member Author

drgrice1 commented Jun 3, 2025

Since we lock in the version of MathJax used by webwork (via the package-lock.json file), we will just remove this code when we update. I added a note in the comment.

@Alex-Jordan
Copy link
Contributor

Looks like MJ4 will use pnpm instead of npm. Not sure what that means wrt the package lock file, but there will be a lot to look into when we go to MJ4.

https://github.com/mathjax/Mathjax-src/releases

@drgrice1
Copy link
Member Author

drgrice1 commented Jun 3, 2025

That is for their package management. That does not affect what we use.

@dpvc
Copy link
Member

dpvc commented Jun 3, 2025

That's right. The pnpm dependency would only come into play if you were rebuilding MathJax from source. The mathjax npmjs package can be loaded via npm or pnpm, just like it is now.

Copy link
Contributor

@somiaj somiaj left a comment

Choose a reason for hiding this comment

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

This works in my tests. My gut feeling is this is probably the better approach.

@Alex-Jordan Alex-Jordan merged commit 79f2c55 into openwebwork:WeBWorK-2.20 Jun 18, 2025
2 checks passed
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.

4 participants