[tex4ht] MathJax support

Nasser M. Abbasi nma at 12000.org
Sun Dec 9 23:39:35 CET 2018


On 12/9/2018 2:20 PM, Michal Hoftich wrote:
>> May be the order is now messed up from before when it worked?
>>
>> Because I am doing additional MathJax.Hub.Config({ in my .cfg,
>> which does show in HTML, something now went wrong? This all worked
>> before. I need these additional fixes in my .cfg.
>>
>> I am attaching my .cfg file. Can you please try on your end?
> 
> 
> The issue is that you use \Configure{@HEAD}{} in your configuration
> file. It removes all configurations that goes to the HTML header,
> including MathJax loading. In fact, I don't think you need to
> configure VERSION, DOCTYPE, HTML and first three @HEAD (for charset,
> generator and css file). You should just remove it, make4ht already
> produces HTML 5 file.
> 
> Best regards,
> Michal
> 

hi Micahl;

But this is severe restriction now that users can no longer
use \Configure{@HEAD} in their .cfg files?

I need to use \Configure{@HEAD} to add javascript code

\Configure{@HEAD}{\HCode{<SCRIPT TYPE="text/javascript">
etc...

For many other things I need not related to mathjax, which
I did not show in the file I send since it was not related.

I load lots of other Javascript libraries etc... using HEAD. One
such example is

\Configure{@HEAD}{\HCode{
     <script type="text/javascript" src="/scripts/gifffer-master/lib/gifffer.js"></script>\Hnewline
<script>
    window.onload = function() {
    Gifffer();
    }
</script>\Hnewline	
}}

and others like it.

How else would one do these things if one can't do them using HEAD in
my common site .cfg file?

Is it posssible to design your mathjax configuration without this restriction
on users .cfg not being able to use \Configure{@HEAD}
by any chance? In the way you had it before, this was not an issue
and it worked well.

Thank you,
--Nasser





More information about the tex4ht mailing list