Wikimedica / mediawiki-extensions-PWA

PWA extension for MediaWiki
GNU General Public License v3.0
2 stars 3 forks source link

duplicated "MediaWiki" #4

Open Stonebubble opened 1 year ago

Stonebubble commented 1 year ago

The extension takes the specified page and adds a "MediaWiki:" in front of it. https://github.com/Wikimedica/mediawiki-extensions-PWA/blob/3e9fa459dfb462d78c86151a492b14e582b0837c/PWA.php#L136 Therefore, the manifest must be in two places at the same time. Because changing the config from "MediaWiki:Manifest.json" to "Manifest.json" would solve the duplication in the links, but then the config can't be found.

Stonebubble commented 1 year ago

In addition, some mediawiki installtions don't use "/index.php?title=" but rather "/w/" configured in $wgActionPaths['view']. (The same is true for action=raw: "/w/MediaWiki:Manifest.json/raw")

bitsofmymind commented 1 year ago

This forces the manifest to be defined in the MediaWiki namespace. I've corrected the example in https://www.mediawiki.org/wiki/Extension:PWA. Is it clearer ?

As suggested in #3, fetching the manifest using the API would probably solve this issue of some MW installations defining their own action paths.