Configure Global Search
Framework M provides a built-in Global Search feature (Command Palette) that allows users to quickly navigate the workspace.
What does Global Search do?
Global Search acts as a central hub for navigating the application. It provides:
- DocType Navigation: Search for registered DocTypes (e.g., "Finance Customer") and jump directly to their list views.
- Document Search: Search for specific records across your application's database (if your backend search adapter supports full-text indexing).
- Commands: Quickly trigger application commands or workspace actions.
- Navigation Shortcuts: Jump to various configured routes or plugin pages.
Users can open the Global Search modal by:
- Clicking the Search icon in the Primary Rail (sidebar).
- Using the keyboard shortcut:
Cmd+G(Mac) orCtrl+G(Windows/Linux). Note:Cmd+K/Ctrl+Kis also supported as a legacy alias.
Enabling or Disabling Global Search
In some deployments, you may want to completely disable Global Search (for example, if you are rolling out a new search dialect, if your application does not require it, or for performance reasons).
You can control the availability of Global Search through environment variables.
To disable Global Search, set the following environment variable in your workspace .env file (or monolith.env / macroservice.env depending on your deployment):
FRAMEWORK_M_GLOBAL_SEARCH=false
What happens when it is disabled?
When FRAMEWORK_M_GLOBAL_SEARCH is set to false, the framework ensures that:
- UI Elements are Hidden: The search icon in the Primary Rail is completely removed.
- Shortcuts are Disabled: The
Cmd+G/Cmd+Kkeyboard shortcuts will no longer trigger the Command Palette. - Modal is Unmounted: The Command Palette React component is not rendered, ensuring no unnecessary background API requests are made to
/api/v1/search/global.
Note: Since this configuration is injected into the frontend build via Vite, you will need to restart your development server (m dev) for the environment variable changes to take effect in the browser.