Let me share my latest #AMP Accelerated Mobile Pages #WordPress presentation held at WordUp #Trójmiasto meetup.

Just a recap of the main thoughts about AMP:

#AMPHTML

AMP HTML is HTML with some restrictions for reliable performance.

#AMPJS

The AMP JS library ensures the fast rendering of AMP HTML pages.

#AMPCache

The Google AMP Cache can be used to serve cached AMP HTML pages.

Allow only asynchronous scripts

Don’t let extension mechanisms block rendering

Minimize style recalculations

Only run GPU-accelerated animations (position, scale, rotation, opacity)

All #CSS must be inline and size-bound 50KB

Keep all third-party JS out of the critical path (except in amp-iframe )

Font triggering must be efficient

We can prioritise resource loading

No !importants

Enjoy!

https://docs.google.com/presentation/d/1q3vI8Vb5d3RKEIhHRQjtMkz87cffNdWn-dzfacU6u1o/edit#slide=id.g34a814f1d1_1_56

When you need to add  <body class=”parent-SLUGNAME”> class please add the following code to your functions.php file:

add_filter('body_class','body_class_section');

function body_class_section($classes) {
global $wpdb, $post;
if (is_page()) {
if ($post->post_parent) {
$parent = end(get_post_ancestors($current_page_id));
} else {
$parent = $post->ID;
}
$post_data = get_post($parent, ARRAY_A);
$classes[] = 'parent-' . $post_data['post_name'];
}
return $classes;
}

Below you’ll find me newest presentation of what’s new in WordPress 4.9

To remove comments rss feed link (and clear othe unnecessary options) just add the following to functions.php file of your theme: