v0.3.7
π― Major Features
Universe Service Refactor
Complete architectural overhaul of the Universe service with separation of concerns into specialized sub-services:
- ExtensionManager: Manages extension loading, engine instances, and lifecycle hooks
- RegistryService: Fully dynamic, Map-based registry system for cross-engine resource sharing
- MenuService: Dedicated menu item and panel management with event support
- WidgetService: Dashboard widget registration and retrieval system
- HookService: Application lifecycle hooks and custom event hooks
Key Benefits:
- Improved performance with lazy loading and proper engine lifecycle management
- Better separation of concerns and maintainability
- Enhanced cross-engine resource sharing via Ember's application container
- Backward compatibility maintained through facade pattern
Enhanced Extension System
New Extension Patterns:
extension.jshook patterns withsetupExtension()andonEngineLoaded()supportwhenEngineLoaded()utility method that handles both loaded and not-yet-loaded engines- Comprehensive extension checking methods:
isInstalled(),isEngineLoaded(),isEngineLoading() - Automatic hook execution for router-loaded engines
Engine Loading Improvements:
- Fixed race conditions between engine loading and hook registration
- Proper tracking of router-loaded engines in
loadedEnginesMap - Patched
buildChildEngineInstanceto run hooks for router-loaded engines - Two-phase extension setup: registration first, then hook execution
Performance Optimizations:
extensions.jsonloading with localStorage caching- Reduced console noise by removing excessive debug logs
- Performance monitoring for extension load times
Helper Registration System
- Cross-engine helper sharing via application container
registerHelper()method for template helpers- Support for both class-based and function-based helpers
- Automatic registration to application container for global access
Component Registration Enhancements
registerRenderableComponent()for cross-engine component sharing- Support for component classes via
ExtensionComponent - Automatic component registration to engine containers
getRenderableComponents()for retrieving registered components
π§ API Improvements
UniverseService
getService()method with flexible naming pattern resolution:- Short names:
"menu"βuniverse/menu-service - Plural variations:
"hooks"or"hook"βuniverse/hook-service - CamelCase:
"menuService"βuniverse/menu-service - Full names:
"menu-service"βuniverse/menu-service - With namespace:
"universe/menu-service"βuniverse/menu-service
- Short names:
whenEngineLoaded()for simplified engine-dependent setupgetServiceFromEngine()for accessing engine-specific servicesgetApplicationInstance()with fallback towindow.Fleetbase
MenuService
- Computed getters for template access:
headerMenuItems,adminMenuItems,adminMenuPanels - Event triggers for backward compatibility
- Proper
finalViewnormalization for all menu items onClickhandlers wrapped withmenuItemanduniverseparameters- Fixed panel item slug/view structure to match original behavior
WidgetService
- Per-dashboard widget registration
registerWidgets()for making widgets available on dashboardsregisterDefaultWidgets()for auto-loading specific widgets- Proper widget filtering by dashboard ID
π Bug Fixes
Extension Loading
- Fixed
owner undefinederrors during engine initialization - Resolved timeout errors during engine boot
- Fixed duplicate dashboard ID errors
- Corrected engine instance tracking and retrieval
- Fixed race conditions in extension setup
Menu System
- Fixed registry name mismatch for header menu items
- Added missing properties to
MenuItem(section, view, slug, etc.) - Corrected panel item structure for proper routing
- Added null checks before
dasherizecalls - Fixed
onClickhandler parameter passing
Registry System
- Fixed widget registry lookup to work with array storage
- Proper filtering by registration key
- Shared registries Map across all engines via container
- Triggered reactivity when creating new registries
Service Resolution
- Fixed service injection on engine boot
- Corrected service map injection
- Fixed
virtualRouteRedirectandgetViewFromTransitionmethods
π¦ Exports & Structure
- Named exports on "exports" namespace
- Separated default and named exports in app/exports re-exports
π ResourceActionService
- Allow properties to be set from initialization options
- Improved flexibility for service configuration
What's Changed
- feat: Complete UniverseService Refactor - Service Decomposition & Lazy Loading by @roncodes in #67
- v0.3.7 by @roncodes in #66
Full Changelog: v0.3.6...v0.3.7