Comments (12)
Sure, sure, I get it.
From my perspective, I'm just trying to give the best experience possible to the users of my editor (users who are at least partially accustomed to the \(
syntax). I'm not arguing that this project should support all things LaTeX (e.g., supporting \begin{align}
), but I am arguing that supporting \(
is a very pragmatic thing to do.
from remark-math.
I totally agree with you. Lets stick with $
and $$
from remark-math.
If someone wants this btw, packages/remark-math
can be forked to add that. rehype-katex
and such will still work if you expose the same math node in Markdown!
from remark-math.
yeah I understand, that's nice. I believe using $
only will be better, even though it takes more time to migrate, it's worth the effort.
from remark-math.
I don’t think it’d be good for markdown to standardize several syntaxes. I think we’re in a position to push for one syntax, as the most popular markdown parser, and I think we should do that. Again: you can do whatever you want with plugins, but I don‘t think we should make it easier.
from remark-math.
While supporting this wouldn’t be too hard to implement (although brittle: the backslashes, parens, and square brackets will interfere with other Markdown constructs, whereas dollars are not in use), I’m not really in favor of adding it: I prefer that remark (and other markdown parsers) push a single way to do things. Having multiple ways to do a similar extension makes the Markdown you write less portable.
from remark-math.
I (a person on the internet) disagree with this decision.
Using \(
is not a config option, it's part of LaTeX syntax and is actually ENCOURAGED: https://tex.stackexchange.com/questions/510/are-and-preferable-to-dollar-signs-for-math-mode.
I understand that TeX !== LaTeX but it still feels like a thing that should be supported.
from remark-math.
We’re not necessarily covering (la)tex here though: it’s about math in markdown in general, which could be mathml or asciimath syntax too.
And, see #39 (comment): you can do this yourself if you want to!
from remark-math.
I don't feel like users should have to fork the project to be able to do this. Is it really that complex to implement here? It seems like it's not (but I might be mistaken).
from remark-math.
@travigd there's a fine line here.
Adding configuration for markers may have value to discuss on it's own.
The push back is on reason presented, which appears to be "it's in latex, so it should be here".
That is a non-goal, markdown is not latex.
If you want a latex transformer, contributions towards syntax-tree/ideas#6 are welcome!
If there is a markdown focused reason, it may be worth exploring.
from remark-math.
If someone wants this btw, packages/remark-math can be forked to add that. rehype-katex and such will still work if you expose the same math node in Markdown!
Can you give some examples on how to do this exactly? Looking at the package code, I'm a little lost albeit I haven't made my own plugin before.
from remark-math.
@danny-avila see the guide to plugins and ASTs at https://unifiedjs.com/learn/
And extending the parser at https://github.com/micromark/micromark#creating-a-micromark-extension
from remark-math.
Related Issues (20)
- invalid javascript @ generated object keys HOT 21
- The dollar sign is not showing in single $ quote HOT 6
- rehype-mathjax should not have a dependency on @types/web HOT 13
- Generate (`pre` and) `code` elements instead of `div`, `span` HOT 1
- Hard break identifier immediately preceding $$ is not registered as a hard break. HOT 6
- Next.js hydration issue HOT 9
- Add mhchem support to rehype-katex HOT 14
- `rehype-katex` does not catch non-parse errors HOT 7
- Math and Katex renders incorrectly HOT 2
- remark-katex @mdx-js/rollup integration HOT 7
- rehype-mathjax: CHTML not rendering HOT 10
- Update KaTeX types HOT 5
- Mathjax Docs are Incorrect Due to Removal of index.js HOT 3
- MathJax error -- TypeError: Cannot read properties of null (reading '4') HOT 11
- Cannot read properties of undefined (reading 'mathFlowInside') HOT 14
- [Nuxt MDC] reading 'mathFlowInside' undefined when parsing a multi-line formula HOT 4
- Older version of `jsdom` (<23) causes deprecation warnings HOT 5
- Add a rehype plugin to use mathlive renderer HOT 3
- rehype-katex breaks in production build HOT 6
- mhchem doesn't seem to work with rehype-katex HOT 5
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from remark-math.