GitbookIO / plugin-mathjax

MathJAX plugin for GitBook
Apache License 2.0
89 stars 51 forks source link

Error with plugin "mathjax": #44

Open Wind0ranger opened 4 years ago

Wind0ranger commented 4 years ago

D:\workspace\blog\interview_books>gitbook build info: 8 plugins are installed info: 7 explicitly listed info: loading plugin "mathjax"... ERROR

PluginError: Error with plugin "mathjax": Cannot find module 'mathjax/unpacked/MathJax'

jiangzhonglian commented 4 years ago

info: loading plugin "mathjax"... ERROR

PluginError: Error with plugin "mathjax": Cannot find module 'mathjax/unpacked/MathJax'

jinghzhu commented 4 years ago

I also encounter the same issue:

$ gitbook serve .
Live reload server started on port: 35729
Press CTRL+C to quit ...

info: 15 plugins are installed
info: loading plugin "page-toc"... OK
info: loading plugin "mathjax"... ERROR

PluginError: Error with plugin "mathjax": Cannot find module 'mathjax/unpacked/MathJax'

Here is my env:

$ gitbook -V
CLI version: 2.3.2
GitBook version: 3.2.3
$ npm -v
6.12.1

book.json:

{
    "plugins": [
        "mathjax",
        "anchors",
        "splitter",
        "prism", 
        "-highlight",
        "book-summary-scroll-position-saver",
        "tbfed-pagefooter",
        "expandable-chapters",
        "search"
    ]
}

This happens after I install latest GitBook.

starplanet commented 4 years ago

I have the problem too. Any solution?

ohmyvander commented 4 years ago

You need to install mathjax@2 in your node_modules. Note that do not install mathjax@3 because the usage of it has changed and there is no unpacked directory in it.

dimpase commented 3 years ago

is there a plan to switch to mathjax@3 ?