mirror of
https://github.com/facebook/docusaurus.git
synced 2025-06-20 03:32:29 +02:00
refactor(theme-common): rename useDynamicCallback to useEvent (#7671)
This commit is contained in:
parent
9473508c33
commit
2c7012f706
7 changed files with 15 additions and 15 deletions
|
@ -20,7 +20,7 @@ import {
|
|||
HtmlClassNameProvider,
|
||||
usePluralForm,
|
||||
isRegexpStringMatch,
|
||||
useDynamicCallback,
|
||||
useEvent,
|
||||
} from '@docusaurus/theme-common';
|
||||
import {
|
||||
useTitleFormatter,
|
||||
|
@ -316,7 +316,7 @@ function SearchPageContent(): JSX.Element {
|
|||
description: 'The search page title for empty query',
|
||||
});
|
||||
|
||||
const makeSearch = useDynamicCallback((page: number = 0) => {
|
||||
const makeSearch = useEvent((page: number = 0) => {
|
||||
algoliaHelper.addDisjunctiveFacetRefinement('docusaurus_tag', 'default');
|
||||
algoliaHelper.addDisjunctiveFacetRefinement('language', currentLocale);
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue