Release status: beta
|Description||Provides an action to show an AMP compliant version of a MediaWiki page.|
|Author(s)||Florian Schmidt (Florianschmidtwelzowtalk)|
The AcceleratedMobilePages extension provides an action for pages in the main namespace to show an AMP compliant version of the page.
- https://github.com/droidwiki/mediawiki-extensions-AcceleratedMobilePages/archive/master.zip and place the file(s) in a directory called
- Add the following code at the bottom of your
wfLoadExtension( 'AcceleratedMobilePages' );
- Done – Navigate to Special:Version on your wiki to verify that the extension is successfully installed.
The extension enables a new action,
amp, on every page in the main namespace. Assuming, you've a page called
MySuperContentPage on your wiki, and short URLs are enabled, you can navigate to the following URL to open the AMP compliant version of that content page:
On this page, the original one is linked as a canonical link, as required by the AMP documentation. Also, the content page get's a new link entry,
amphtml, as well, linking to the
Customizing the styling
The style of the amp compliant pages is borrowed from the MobileFrontend extension and minimized to the absolute required set of instructions. AMP has the goal to make pages as fast as possible while loading them, in order to achieve that, this extension targets to have a minimal set of styling rules, only.
Currently, also, the styling can not be customized or replaced without changing the extension code, which would make upgrading this extension impossible and is not recommended nor supported. If the styling does not fit your needs, please open an issue and explain the reasons why additional styling is needed.
Because of the nature of this extension, there're a lot of limitations, this extension has, especially when comparing a fully-featured MediaWiki page with an AMP optimized one, which only target is a user reading it. Refer to the README of the extension to see a full list of current limitations.