Active Modules
Active Modules
Starting from version 2026.3.0, the admin UI dynamically hides navigation items for inactive modules. This is powered by the useActiveModules composable.
How it works
- During app initialization (
initGlobalSettings), the admin fetches the list of active modules from the backend/modulesendpoint. - The module list is cached in
localStorageunder the keyCACHE_KEY_ACTIVE_MODULES. - Navigation items annotated with a
modulefield are filtered: only items whose module is active are shown.
Module annotations
Navigation items in navigation.js and module-specific navigation-config.js files can include a module field:
{
title: 'nav.a.posts',
icon: 'post',
to: { name: 'post-manage' },
module: 'Content', // hidden when Content module is inactive
}
Current module annotations
| Navigation Item | Module |
|---|---|
| Posts | Content |
| Contacts | Content |
| Products | Product |
| Orders | Ecommerce |
| Real Estate | RealEstate |
| Education | Education |
| Game | Game |
Composable API
import { useActiveModules } from '@/composables/useActiveModules'
const { isModuleActive, fetchAndCacheActiveModules, activeModuleSet } = useActiveModules()
// Check if a module is active (case-insensitive)
isModuleActive('Education') // true or false
isModuleActive('education') // same result
// Force refresh from backend
await fetchAndCacheActiveModules()
// O(1) lookup via computed Set
activeModuleSet.value.has('CONTENT')
Backend endpoint
The admin calls GET /v2/admin/modules to retrieve the active module list. The response is an array of module objects with at minimum a name field.
Caching behavior
- Modules are fetched once during app initialization.
- Cached in
localStorageto avoid repeated API calls on page refresh. - Cache is refreshed when the user explicitly triggers a module activation change in settings.
Module name matching
Module names are compared case-insensitively. Use the canonical module name (e.g., Content, Education, RealEstate) when annotating navigation items.

