-
-
Notifications
You must be signed in to change notification settings - Fork 1.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
Simple Example with Typescript #2310
Comments
Peter:
I'm trying to get mathjax embedded in a Vue component using typescript and am trying to get something simple working. I found a nice example (without vue) using the beta version of 3.0 at https://stackblitz.com/edit/mathjax-ts <https://stackblitz.com/edit/mathjax-ts>.
I would not recommend using the typescript source, but rather the compiled version in the js directory. The files are designed to be run from that directory.
I installed MathJax via yarn and it seems that the directory structure is different from the beta version, however if I use
import { MathJax } from 'mathjax-full/ts/mathjax'; // this is the typescript file.
Use
import {mathjax} from 'mathjax-full/js/mathjax.js';
instead.
and I seemed to find versions of TeX, CHTML, etc. in the mathjax-full package that replace those in the example in https://stackblitz.com/edit/mathjax-ts <https://stackblitz.com/edit/mathjax-ts>.
That example is a bit out of date, as the directory names have changed since it was created. The mathjax3/mathjax3 directory is now the mathjax-full/js directory.
Hope that helps.
Davide
|
Davide, If I understand things right, the In fact, there doesn't seem to be a |
There is a build process that is performed before the If you checked out the
to build the (Sorry, I missed your response, and just saw it now as I was cleaning up some issues for the 3.0.1 release.) |
I'm trying to get mathjax embedded in a Vue component using typescript and am trying to get something simple working. I found a nice example (without vue) using the beta version of 3.0 at https://stackblitz.com/edit/mathjax-ts.
I installed MathJax via yarn and it seems that the directory structure is different from the beta version, however if I use
and I seemed to find versions of
TeX
,CHTML
, etc. in themathjax-full
package that replace those in the example in https://stackblitz.com/edit/mathjax-ts.However when trying to run this, there is a large list of missing packages. For example, in the
mathjax-full/ts/mathjax.ts
file, the top line is:which does not exist, however
./core/HandlerList.ts
does?I looked through the documentation, but can't seem to find anything about a typescript example.
The text was updated successfully, but these errors were encountered: