Making WordPress.org


Ignore:
Timestamp:
03/25/2020 06:40:50 AM (4 years ago)
Author:
coffee2code
Message:

Theme Directory: Sync the postsPerPage value localized to the JS with value set via posts_per_page option.

In preparation of reducing pageload overhead by loading 12 themes at a time instead of 24. This change will allow JS and non-JS values to match and be changeable via WP admin.

Props dufresnesteven.
See #5062.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • sites/trunk/wordpress.org/public_html/wp-content/themes/pub/wporg-themes/functions.php

    r9622 r9631  
    135135                ),
    136136                'isMobile'     => wp_is_mobile(),
    137                 'postsPerPage' => 24,
     137                'postsPerPage' => get_option( 'posts_per_page' ),
    138138                'path'         => trailingslashit( parse_url( home_url(), PHP_URL_PATH ) ),
    139139                'locale'       => get_locale(),
Note: See TracChangeset for help on using the changeset viewer.