fix: render search bar component regardless of whether any active plugins are found

This commit is contained in:
Hossein Mehrabi
2023-06-13 17:54:30 +03:30
parent e10d9abf15
commit 339d5bcd91
@@ -1,12 +1,8 @@
import ErrorBoundary from '@docusaurus/ErrorBoundary'
import { useActivePlugin } from '@docusaurus/plugin-content-docs/lib/client/index.js'
import React from 'react'
import { SearchBar } from './SearchBar'
const SearchBarWrapper: React.FC = () => {
const activePlugin = useActivePlugin()
if (!activePlugin) return <></>
return typeof window === 'undefined' ? (
<></>
) : (