Does not seem to load with MinervaNeue on 1.36.1
I am using 0.8.2 on MW 1.36.1 with MobileFrontend 2.3.0 (f78273c) and MinervaNeue (20711d8) from May 28th 2021. On pages rendered with MinervaNeue the JS is not included at all and the expressions are not rendered.
Prior to this I used 0.7.4 with 1.35.2 which worked fine.
Same with this issue. My docker compose file as follows:
version: '3'
services:
mediawiki:
image: mediawiki:1.36
container_name: mwiki
restart: always
ports:
- 4095:80
links:
- database
volumes:
- ./LocalSettings.php:/var/www/html/LocalSettings.php
- ./extensions/SimpleMathJax:/var/www/html/extensions/SimpleMathJax
- ./extensions/MobileFrontend:/var/www/html/extensions/MobileFrontend
- ./skins/MinervaNeue:/var/www/html/skins/MinervaNeue
database:
image: mariadb:10.6-focal
container_name: db
restart: always
volumes:
...
environment:
...
Minerva Neue is 20711d8.
When I access my wiki with ?debug=true, it outputs
OutputPage::transformFilePath: Failed to hash /var/www/html/extensions/SimpleMathJax/resources/resources/ext.SimpleMathJax.js
in console.
It works with other themes.
@6cdh, I am not getting this error with my installation but you could try getting rid of it by editing extension.json from
"ResourceModules": {
"ext.SimpleMathJax": {
"scripts": ["resources/ext.SimpleMathJax.js"]
}
},
"ResourceFileModulePaths": {
"localBasePath": "",
"remoteExtPath": "SimpleMathJax/resources"
},
to
"ResourceModules": {
"ext.SimpleMathJax": {
"scripts": ["ext.SimpleMathJax.js"]
}
},
"ResourceFileModulePaths": {
"localBasePath": "resources",
"remoteExtPath": "SimpleMathJax/resources"
},
, although I am not sure this is the correct solution.
@Yuubari, thanks, the error disappears though math equations still don't get rendered.
After several hours of research, I found this workaround. Change
https://github.com/jmnote/SimpleMathJax/blob/ddcac9ac1616aed794576f2914ee426879194f0f/resources/ext.SimpleMathJax.js#L1
to
mw.hook( 'wikipage.content' ).add( function ( $content ) {
This does not seem to work in my case (I am not using Docker, though); thank you for the pointer, though. I think I will try deploying a test MW instance to debug this properly.
This fork works with me. Have a try.