Skip to content
This repository was archived by the owner on Feb 19, 2025. It is now read-only.

Commit 22f6227

Browse files
committedJul 18, 2018
fix(paginate): Exclude pagination pages from jekyll-paginate
Fixes algolia#76
1 parent bef6d32 commit 22f6227

File tree

2 files changed

+12
-0
lines changed

2 files changed

+12
-0
lines changed
 

‎lib/jekyll/algolia/configurator.rb

+8
Original file line numberDiff line numberDiff line change
@@ -244,10 +244,18 @@ def self.extensions_to_index
244244

245245
# Public: Disable features from other Jekyll plugins that might interfere
246246
# with the indexing
247+
# Note that if other jekyll plugins are defined as part of the
248+
# :jekyll_plugins group in the Gemfile, we might be able to override them
249+
# using .load_overwrites in .load_overwrites in jekyll-algolia.rb.
250+
# If they are simply required in Gemfile, then we might need to revert
251+
# their values to nil values from here
247252
def self.disable_other_plugins(config)
248253
# Disable archive pages from jekyll-archives
249254
config['jekyll-archives'] = nil
250255

256+
# Disable paginatio from jekyll-paginate
257+
config['paginate'] = nil
258+
251259
# Disable tags from jekyll-tagging
252260
config['tag_page_dir'] = nil
253261
config['tag_page_layout'] = nil

‎spec/jekyll/algolia/configurator_spec.rb

+4
Original file line numberDiff line numberDiff line change
@@ -438,6 +438,10 @@
438438
it { should include('jekyll-archives' => nil) }
439439
end
440440

441+
context 'disable jekyll-paginate' do
442+
it { should include('paginate' => nil) }
443+
end
444+
441445
context 'disable jekyll-tagging' do
442446
it { should include('tag_page_dir' => nil) }
443447
it { should include('tag_page_layout' => nil) }

0 commit comments

Comments
 (0)
Failed to load comments.