Problem
Service startup may take long enough that an application needs to display a responsive splash screen. Today services start before the native event loop, so a Wails window cannot render or remain interactive during that work.
Proposed lifecycle
- Enter the native platform event loop.
- Emit
events.Common.ApplicationStarting once native window operations are available.
- Run the existing
ServiceStartup methods sequentially on a background startup goroutine.
- Emit
events.Common.ApplicationInitialized only after every service starts successfully.
- Release pending application windows.
This does not change the service API and does not introduce a special splash-window concept. Applications create hidden windows and decide which window to show from lifecycle listeners.
Acceptance criteria
- The native UI event loop remains responsive during a blocking
ServiceStartup.
ApplicationStarting listeners run before service startup begins.
ApplicationInitialized is emitted only after successful service startup.
- Startup errors cancel and shut down already-started services without deadlock.
- Hidden pre-created windows can be shown from
ApplicationStarting.
- Include a runnable
v3/examples/splashscreen example.
- Preserve sequential service startup and reverse-order shutdown.
Scope
This is a general v3 feature and is not proposed as a v3 beta blocker.
Problem
Service startup may take long enough that an application needs to display a responsive splash screen. Today services start before the native event loop, so a Wails window cannot render or remain interactive during that work.
Proposed lifecycle
events.Common.ApplicationStartingonce native window operations are available.ServiceStartupmethods sequentially on a background startup goroutine.events.Common.ApplicationInitializedonly after every service starts successfully.This does not change the service API and does not introduce a special splash-window concept. Applications create hidden windows and decide which window to show from lifecycle listeners.
Acceptance criteria
ServiceStartup.ApplicationStartinglisteners run before service startup begins.ApplicationInitializedis emitted only after successful service startup.ApplicationStarting.v3/examples/splashscreenexample.Scope
This is a general v3 feature and is not proposed as a v3 beta blocker.