From README Roadmap — Code Quality / Type Safety
Replace the pragmatic UNLOADED_LIBRARY cast in app/store/store.ts with a proper nullable type (library: LibraryType | null) and add real if (!this.library) return; guards at the top of each action.
The current pattern is a type-assertion workaround: all actions assume library is loaded because the UI only renders them in that state, but there is no static guarantee. A proper refactor would surface missing guards as compile errors.
Source: README.md roadmap
From README Roadmap — Code Quality / Type Safety
Replace the pragmatic
UNLOADED_LIBRARYcast inapp/store/store.tswith a proper nullable type (library: LibraryType | null) and add realif (!this.library) return;guards at the top of each action.The current pattern is a type-assertion workaround: all actions assume
libraryis loaded because the UI only renders them in that state, but there is no static guarantee. A proper refactor would surface missing guards as compile errors.Source: README.md roadmap