Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature/wpce 330 algolia autocomplete debounce #433

Open
wants to merge 5 commits into
base: main
Choose a base branch
from

Conversation

daveromsey
Copy link
Contributor

@daveromsey daveromsey commented Oct 25, 2024

Closes https://webdevstudios.atlassian.net/browse/WPCE-330

  • Adds single setting for Algolia Autocomplete debounce timeout with a default to zero, for disabled.
  • Adds filters to allow for the debounce value to be set individually for each index.

image

Here's a plugin to test overriding the debounce timeout value for the searchable_posts index.

<?php
/**
 * Plugin Name:       Algolia Test Site Functions
 * Plugin URI:
 * Description:
 * Version:           1.0.0
 */

namespace AlgoliaTestFunctions;

add_filter( 'algolia_autocomplete_debounce_wp_searchable_posts', __NAMESPACE__ . '\searchable_posts_index_debounce' );
function searchable_posts_index_debounce() {
	return 5000;
}

@daveromsey daveromsey self-assigned this Oct 25, 2024
@daveromsey daveromsey marked this pull request as ready for review October 25, 2024 20:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant