-
Notifications
You must be signed in to change notification settings - Fork 3.2k
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
Insert inline LateX within Slate #1913
Comments
might want to use inline instead of mark and put the latex(e.g \lambda) into data instead of text |
Hey, thanks for using Slate! Unfortunately, we can't offer support for usage questions in the issues here because it becomes overwhelming to maintain the project if the issues are filled with questions. However, we do have a Slack channel and people are constantly asking and answering questions in there. So I'm going to close this issue, but I definitely recommend joining the Slack channel if you want to find people that might be able to help. Thanks for understanding! |
What is the Slack channel name? |
I just wanted to comment here that I did implement math typesetting/editing support in CoCalc using Slate. Math is rendered using katex and editing is done using a CodeMirror editor (all using void elements). To try it out, use https://cocalc.com and create a new project and then a new file in it with extension |
I used mathquill and it worked much better, as in, the editor was working in flow with mathquill so they worked seamlessly. Sadly I have issues, with accessibility, limited functionality and arabic, which makes me believe I may need to fork mathquill, but I haven't found a better combo so far. |
I am using a custom Wrapper on top of slate which offers multiple editor compatibility, but this may give you an idea on how it works.
So this is given to the "renderElement" and the result is a seamless formula. |
|
I am trying to insert an inline LateX formula and am having some difficulties getting the equation rendered properly. To do this, I have created the following data model and fed it to the editor component. The extra blub is marked by
latex
, whosetext
attribute is set to\\lambda
.Following is the method where I analyze the node types:
Following is the method that renders the editor:
As it can be seen in the following image, the letter
lambda
is both rendered as\lambda
andλ
, the latter of which is the expected behavior. Can someone please advise what I might be doing wrong?Note:
InlineMath
comes fromreact-katex
.Thanks!
The text was updated successfully, but these errors were encountered: