The AMP plugin is designed to convert Rainlab.Blog pages into pages that comply with the AMP standard.
The following plugin is required
Installation
- Add AMP plugin to a project.
- Add the AMP component to a page with the blogPosts component.
Documentation
The component has the following properties:
- AMP layout - path to the amp layout. This property is used for replacing default page layout.
- AMP schema type - the type of schema to use on AMP pages.
The plugin has the following settings:
- Organisation name - name of the publisher of the content. Typically, this can be the same as the site name.
- Organization logo - logo for your organization.
The amp component injects the following variables to the amp layout:
.amp.schemaType
- the type of schema to use on AMP pages.amp.organisationName
- the organisation name.amp.organisationLogo.src
- the organisation logo.amp.organisationLogo.height
- the organisation logo height.amp.organisationLogo.width
- the organisation logo width.amp.headline
- a short headline for an AMP article, using fewer than 110 characters and no HTML markup (post title)..amp.datePublished
- the date an article was published..amp.dateModified
- the date an article was most recently modified date..amp.image.src
- an article image to appear in the Top Stories carousel..amp.image.height
- an article image height..amp.image.width
- an article image width..amp.description
- a short description of an AMP article, using fewer than 150 characters and no HTML markup (post excerpt).
You can find more info about AMP and layout examples here.
Troubleshooting
If you like living on the edge, please report any bugs you find on the issues page.
1.0.1 |
First version of Amp Feb 07, 2019 |
---|