diff --git a/_config.yml b/_config.yml index 09eb8f5ae49..1ee01576693 100644 --- a/_config.yml +++ b/_config.yml @@ -150,6 +150,11 @@ pwa: paginate: 10 +# Search result controls +search: + limit: + per_page: 10 + # The base URL of your site baseurl: "" diff --git a/_includes/search-loader.html b/_includes/search-loader.html index 5a43fba8351..1d5b4f2c159 100644 --- a/_includes/search-loader.html +++ b/_includes/search-loader.html @@ -17,16 +17,278 @@
{{ site.data.locales[include.lang].search.no_results }}
{% endcapture %} +{% assign total_posts = site.posts | size %} +{% assign search_limit = site.search.limit | default: total_posts %} +{% assign search_per_page = site.search.per_page | default: site.paginate | default: 10 %}