Skip to content

rebeling/lektor-amp

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

lektor-amp

This plugin creates an Accelerate Mobile Page (AMP) subartifact of the original content artifact and links canonical and amphtml.

Enabling the Plugin

To enable the plugin run this command:

lektor plugins add lektor-amp

Configuring the Plugin

The plugin has a config file to turn off the amp generation. Just create a file named amp.ini into your configs/ folder and set the amp key.

generate_amp = false

In Templates

It expects an amp template version, prefixed with amp- of the templates. Basic example for lektors basic blog module templates is in the github repo (see repo). Just copy theses files into a fresh lektor 3.0 templates folder.

<!doctype html>
<html >
<head>
  <meta charset="utf-8">
  <script async src="https://cdn.ampproject.org/v0.js"></script>
  ...

Beware that various tags, google ads, etc. behaves different and need to be handled in the amp templates (see AMP).

Mobile first, AI is coming by itself ;)

Releases

No releases published

Packages

No packages published