Skip to content
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

Extend markdown plugin to enable MathJax support. #875

Closed
Piyush3dB opened this issue Apr 28, 2017 · 2 comments
Closed

Extend markdown plugin to enable MathJax support. #875

Piyush3dB opened this issue Apr 28, 2017 · 2 comments

Comments

@Piyush3dB
Copy link
Contributor

The extending-markdown-syntax-with-plugins section describes how one can extend the markdown loader to parse, say, MathJax.

I quote part of the section...

If you want to do this you will need to use a custom markdown loader. You can copy the one provided in the default starter here. Add the relevant packages to your dependencies, including the markdown-it plugins that you want to use and enable them with md.use(require('markdown-it-plugin-name')) within the markdown loader file.

But the link pointed to by 'here' i.e.

https://github.com/gatsbyjs/gatsby-starter-default/blob/master/loaders/markdown-loader/index.js

is broken.

Which is the best example I can follow to extend markdown plugins so that I can enable MathJax support?

I have looked at issue #134 which seems to be a hack and not currently the recommended way of doing it. Also, I'd like to be able to just follow the instructions on the README page to achieve this. I'm a C++ dev and this JS stack is very foreign to me so any guidance would be very much appreciated!

@KyleAMathews
Copy link
Contributor

Hey so sorry! The old default starter got moved recently to one named "kitchen sink" and I forgot
to update that link. https ://github.com/gatsbyjs/gatsby-starter-kitchen-sink/blob/master/loaders/markdown-loader/index.js

Could you edit that link in the markdown to point to the new location.

@Piyush3dB
Copy link
Contributor Author

Awesome thanks! I have a partially working solution at gatsbyjs/gatsby-starter-kitchen-sink#1. I'm intending to get this fixed and submit it to the kitchen sink demo.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
2 participants