feat: add LaTeX math formula rendering support#499
Open
MuLeiSY2021 wants to merge 1 commit intoAsyncFuncAI:mainfrom
Open
feat: add LaTeX math formula rendering support#499MuLeiSY2021 wants to merge 1 commit intoAsyncFuncAI:mainfrom
MuLeiSY2021 wants to merge 1 commit intoAsyncFuncAI:mainfrom
Conversation
Add remark-math and rehype-katex plugins to the Markdown component so that LaTeX math expressions (both inline `$...$` and display `$$...$$`) are rendered correctly in wiki pages. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Contributor
There was a problem hiding this comment.
Code Review
This pull request adds support for rendering mathematical expressions in Markdown by integrating the remark-math and rehype-katex plugins. The changes include adding the necessary dependencies to package.json and package-lock.json, and updating the Markdown component to utilize these plugins along with the KaTeX CSS for proper styling. I have no feedback to provide.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
remark-mathandrehype-katexplugins to render LaTeX math expressions in wiki pages$...$) and display ($$...$$) math are now supportedCloses #498
Changes
package.json: addedremark-math@^6.0.0andrehype-katex@^7.0.1src/components/Markdown.tsx: imported and enabled the two plugins, importedkatex/dist/katex.min.cssTest plan
$...$) renders correctly$$...$$) renders correctly🤖 Generated with Claude Code