Questions tagged [katex]

KaTeX is a fast, easy-to-use JavaScript library for TeX math rendering on the web. KaTeX supports all major browsers, including Chrome, Safari, Firefox, Opera, and IE 8 - IE 11.

Filter by
Sorted by
Tagged with
0 votes
0 answers
12 views

How to display mathematics equation from OpenAI API output

It seems that ChatGPT use KaText to render math, but when I paste API output to KaText Demo website. It goes error. (Gauss's Law): \[ \nabla \cdot \mathbf{E} = \frac{\rho}{\varepsilon_0} \] ...
Allen_Tsang's user avatar
0 votes
0 answers
11 views

Katex - how to jump to the equation

I want to use katex (https://katex.org/docs/support_table) to generate math symbols on my website. The environments like align generates numbers like below I'd like to add a button which scroll to ...
Merger's user avatar
  • 49
0 votes
0 answers
15 views

Using latex formulas in astro using markdown and katex: How may I centered the formulas?

I'm trying to create a blog with mathematical formulas in Latex using Astro, with posts in Markdown. Following the instructions from this blog, I've created a minimal example project at this Github ...
Pablo De Napoli's user avatar
0 votes
1 answer
17 views

How can I get subscripts centered below a mathematical symbol in github's markdown, e.g. get expectation to look like summation?

I'm editing a markdown file intended for hosting on github in vscode and using the built-in preview functionality to see how it displays. I cannot get the subscripts to display properly for the ...
phoenixdown's user avatar
0 votes
0 answers
24 views

react-katex parses equation blocks, but doesn't render

I'm trying to display equations using react-katex. The output successfully parses equations enclosed inside $dollar signs$, I'm still seeing the LaTeX code. I don't see them rendered as equations. ...
Caspian's user avatar
  • 151
0 votes
0 answers
23 views

Applying Google's notranslate to all katex blocks

I have a blog built with gatsby.js in which I insert math formulas using gatsby-remark-katex. I noticed that the math blocks it generates are wrapped within elements with class="katex-display&...
Weier's user avatar
  • 1,359
0 votes
0 answers
13 views

KaTeX Seperate Number With Commas

I installed KaTeX on my blog, and I need a way to format a number with commas. By searching around, I found that I could use {\small,} wherever I needed a comma, but that seemed needlessly verbose, ...
ByteAtATime's user avatar
1 vote
1 answer
87 views

Can't render math with Docusaurus

I can't get math equations getting rendered by using KaTex in my markdown files and don't know why. Can anyone help me, please? I tried to reproduce it by creating a new clean Docusaurus project and ...
A.Struve's user avatar
1 vote
0 answers
220 views

How to combine next.js + mdx + katex?

In my next.js project my goal is to render katex equations from mdx file. However my equations are just not rendering. I have the following setup in my page.tsx is import HelloWorld from './hello.mdx'...
shark's user avatar
  • 11
1 vote
1 answer
464 views

How to add a custom TinyMCE plugin with Vue3 (Nuxt) using the PluginManager

I have a Nuxt3 app with TinyMCE for which I already created a standalone plugin for inserting LaTeX that works (latex.min.js). Is it possible to create a TinyMCE plugin that interacts with my web app ...
luxor37's user avatar
  • 48
1 vote
0 answers
173 views

Vscode extension with katex in hover

I had an idea to develop a simple extension for vscode that will help me to display math functions written in latex when I hover over python's comment. Simple example: # $y = x^2$ y = x ** 2 Even ...
Andy Yermakov's user avatar
0 votes
0 answers
175 views

bundle exec jekyll serve works but git build and user.github.io makes build error in 'katex'

I'm having trouble with jekyll git blot plugins. especially the error message was Logging at level: debug Configuration file: /github/workspace/./_config.yml GitHub Pages: github-pages v228 ...
yeonsook kwak's user avatar
0 votes
1 answer
73 views

Latex with katex rendered double in R Shiny app and as unwanted popup in new window

My R Shiny application uses Katex to render the latex - this is my header in my navbarPage() in my ui: header = tags$head( # use Katex to autorender all tex: https://katex.org/docs/...
Natalie A's user avatar
1 vote
0 answers
47 views

Math Rendering in SurveyJS (KaTeX or MathJax)

I'd like to show math in my survey. Has anybody done this before and can explain a way how to achieve this? I have not found any helpful information on this in the SurveyJS documentation or elsewhere.
kassbohm's user avatar
2 votes
1 answer
806 views

Quarto won't render to PDF

I am trying to render my quarto to pdf. This is my Yaml: --- date: last-modified toc: true format: html: code-fold: true html-math-method: katex pdf: geometry: - top=30mm ...
Marianna Sebő's user avatar
0 votes
0 answers
275 views

How can I use 'rehype-katex' and/or 'remark-math' and have copy/paste (from webpage to text editor) copy the underlying LaTeX code?

I just integrated rehype-katex with MDX for Next.js, and it is rendering nicely: However, when I highlight the math-rendered text like "10⁹" in that image, and paste it into my text editor (...
Lance's user avatar
  • 76k
1 vote
0 answers
143 views

Math equations not rendering in docusaurus

Following instructions exactly as they are on: https://docusaurus.io/docs/markdown-features/math-equations Also checked that katex.css was properly loaded. But equations not rendering. Below are the ...
Raj Saha's user avatar
0 votes
0 answers
90 views

Katex parse error: Unknown column alignment

enter image description hereI used anaconda to launch vs-code and opened an .ipynb file and came across the parse error in the title, but it compiled fine in browser (same code). $$u\\left( c \\right) ...
Jame_W's user avatar
  • 1
1 vote
1 answer
163 views

Embedding mathematical equations in an Elm Spa

I want to put mathematical equations in a single page app written in elm. I would like the equations to be rendered in the app and not being embedded as prerendered images. I tried to realize this ...
bitt.j's user avatar
  • 123
1 vote
1 answer
492 views

importing katex.min.css into my React file and webpack.config.js just doesn't work

After an epic fight with my webpack, I need to go to bed. I honestly don't know wtf the issue is. I tried now for hours and copied some webpack configs from the web together. This is my webpack.config....
Dominik's user avatar
  • 123
0 votes
1 answer
49 views

Render KaTeX inside a modal directly without an extra "click" inside the modal in R Shiny

I am struggling ro render the KaTeX formulas inside my popups. The Javascript function I'm using does this, but unfortunately only after i made a "click" inside of the generated popup. And ...
Onur's user avatar
  • 35
0 votes
1 answer
263 views

Nuxt v3 with nuxt-content: how to render math equations in markdown?

I have a new nuxt-content site using Nuxt ([email protected] and @nuxt/[email protected]) and would like to render math equations from my markdown files using the usual $...$ syntax. What do I need to add to get ...
GaryO's user avatar
  • 6,004
1 vote
1 answer
100 views

use mathjax render formula in a class without delimiters

I use markdown_it to convert my Markdown to html, the converted formula lost its delimiters, which caused my mathjax cannot render the formula, my mathjax confirmation is : <script src="https:/...
iMath's user avatar
  • 2,346
0 votes
0 answers
28 views

How to move the cursor only to the text present inside multiple span tags with left and right arrow key

Can you please help me to write a logic to move the cursor only to the text in a content editable div. Here <span id="katexdivspanidcount_3" has multiple tags so when I try to move the ...
Vignesh Jayaraman's user avatar
0 votes
0 answers
38 views

Insert a node next to the inserted node in Javascript Getselection Range

On keydown event, I need to print the character with span tag. Each character should be in a separate span tag.I am using a content editable div and I need to insert the characters based on the ...
Vignesh Jayaraman's user avatar
2 votes
1 answer
98 views

LaTeX commands to type > (greater than) and < (less than) in KaTeX

Youtrack and many other web apps use KaTeX to render mathematical notation and markdown for all other things. However markdown parser treats certain characters in a special way and interferes with ...
Dima Chubarov's user avatar
0 votes
1 answer
96 views

How can one include Js code for rendering KaTeX by reactable in R Shiny?

I need to create a table with reactable for my shiny app witch should contain a lot of math formula (in row and column), so unfortunately mathjax isnt really an option because of its client-side-...
Onur's user avatar
  • 35
2 votes
1 answer
64 views

How to use regex to find in between words and spaces?

I'm so frustrated and lost. I would really appreciate your help here. I'm trying to fix an issue in Katex and Guppy keyboard. I'm trying to generate a regex to find between the word matrix and find ...
timmyx's user avatar
  • 166
0 votes
0 answers
34 views

Katex loading math quation with Padding on Bottom

I am using Katex in react native and it is showing me some space on the below as per image As 1320 is in the F(x) form so it. I am using https://cdn.jsdelivr.net/npm/[email protected]/dist/katex.min.js ...
Rover's user avatar
  • 671
1 vote
0 answers
314 views

Render Quill editor math content in React

I have a rich text editor that supports mathematical expression, its working fine expressions can be written and rendered fine in the editor but when we try to render using div it throws many errors ...
sonus21's user avatar
  • 5,218
0 votes
1 answer
229 views

Newtonian notation for derivates on latex

I am using Notion for my studies: so I have to use Latex to represent the equations or others math stuffs. I noticed that I can use the Newtonian notation on Latex with the command \dot or \ddot (...
Emiliano Cacciuto's user avatar
0 votes
1 answer
193 views

Katex absolute value symbols do not render as expected

I am unsure as to why the demo at: https://katex.org can render the following LaTex correctly: \left| \frac{1}{2} \right| as it will output: image. However, when I try to do the same (with the same ...
FuzzyPenguin's user avatar
0 votes
1 answer
67 views

Katex not working in Firefox on dynamically created formulas

I have math delimiters wrapped in span. Therefore, before rendering math, I unwrap delimiters and then render math. This works in Chrome, but not in Firefox. Why? https://jsfiddle.net/2zk3su9w/
Paul R's user avatar
  • 2,671
1 vote
0 answers
51 views

Templating KaTex String through Javascript template literals

I have got KaTeX strings which I'm trying to template through javascript template literals. But the results are not rendered properly instead the raw strings $$10 b^2$$ sq. units are displayed in the ...
Maniyan's user avatar
  • 35
0 votes
1 answer
55 views

Special Letters not working on KATEX on Github

After May 2022, github are now accepting KATEX directly on markdown using $$$$ I'm trying to use the following letters on markdown using the $$$$ special characters to use the KATEX on my github but ...
F4NT0's user avatar
  • 873
1 vote
1 answer
87 views

KaTeX and dynamic content

I have an HTML document with dynamic content including mathematical formulas. I would like to render the dynamically generated mathematics using KaTeX. Following various suggestions online, my current ...
kacper's user avatar
  • 75
2 votes
2 answers
2k views

Latex equation does not properly split in quarto

Goal To render a long latex equation in two lines in quarto YAML --- title: "ABC" description: "XYZ" format: html: page-layout: full toc-location: left html-math-...
umair durrani's user avatar
0 votes
1 answer
499 views

Create chemical equilibrium symbol in Katex

I'm trying to create this symbol in KaTex: (I know there are the KaTex commands \xrightleftharpoons{} and \rightleftharpoons, but they make both arrows the same length.) It's for an explanation of ...
Anton's user avatar
  • 583
1 vote
1 answer
133 views

Global macros for KaTeX in docusaurus

I'm trying out docusaurus to write a rather technical manual. One of the requirements is LaTeX support with macros. Macros allow me to make fewer mistakes and easily change how some output looks for ...
Peter's user avatar
  • 2,972
1 vote
1 answer
151 views

gatsby-remark-katex plugin in my Gatsby blog is not working correctly

I want to be able to render Math equations in my Gatsy blog both in inline mode & display mode. I write my blogs using Markdown. I installed the gatsby-remark-katex plugin by folling the ...
HKS's user avatar
  • 694
0 votes
1 answer
175 views

How to represent long division using KaTeX?

I checked the official KaTeX docs and there seems to be no support for long division. Is there another way I can represent long division using KaTeX?
Jeff Zhou's user avatar
3 votes
1 answer
371 views

Katex rendering equations multiple times

I am using Docusaurus to generate a static website. I integrated katex using the official instructions (https://docusaurus.io/docs/next/markdown-features/math-equations). I want to render this: $$ \...
Leon Bohmann's user avatar
0 votes
1 answer
643 views

How to left-aling formulas and not center them in jupyter notebooks

I would like to know how to left-align formulas in jupyter notebooks and I would also like the formulas not to be centered, but to start at the left edge of the notebook. I've already read many ...
fabianod's user avatar
  • 510
0 votes
1 answer
297 views

IPython.display.Markdown does not render KaTeX correctly

When trying to display a mathematical equation, it seems as if KaTeX only considers the first letter following a \ when rendering the equation. Here is an example: from IPython.display import Markdown ...
tlouw's user avatar
  • 3
5 votes
1 answer
959 views

GitLab stops rendering in-text LaTeX for markdown files after 50 occurrences

I have been using GitLab's LaTeX rendering feature in Markdown, and enjoy it tremendously. That being said, I have found that there is an upper limit to the number of in-text latex references. After ...
Luc Le Pottier's user avatar
1 vote
1 answer
527 views

Weird plain-text duplication in MDX after LaTeX equation

I am trying to integrate the MDX with remark-math and rehype-katex plugin on Next.js. However, after I successfully added the plugins, there are a plain-text duplication after the equation. Here is ...
Parakorn Leknamongkol's user avatar
1 vote
0 answers
769 views

React Latex/Katex/MathJax

Help me to understand. How can I use latex in react in this way \documentclass{article} \usepackage{xlop} \begin{document} \opdiv{6000}{34} \opdiv[maxdivstep=3]{6000}{34} \end{document} result/...
enhor's user avatar
  • 11
2 votes
1 answer
961 views

render math equations in vue

Math equations are not rendered the way it should be when fetched from database in vue. Its happening in chrome but working fine in firefox. Like this - In chrome: In firefox: Through some research ...
alprazolam's user avatar
1 vote
1 answer
616 views

I am unable to render Math in docusaurus

Reading the documentation, I have followed all the steps. With my docusaurus.config.js files here. // @ts-check // Note: type annotations allow type checking and IDEs autocompletion const ...
Manash Baul's user avatar
0 votes
0 answers
75 views

How To fast render data using katex in react native?

Question :- How To fast render data using katex in react native? Description :- I am using Katex, When app is run then katex data is shown after 2-3 seconds. How it is fast like app is run then data ...
Gyan Prakash's user avatar