mirror of
https://github.com/google/blockly.git
synced 2026-01-06 00:20:37 +01:00
* refactor(events): Introduce type predicates for event classes Introduce predicates for testing Abstract event subclasses based on their .type properties. These are useful because there are places where it is not possible to use instanceof <ClassConstructor> tests for type narrowing due to load ordering issues that would be caused by the need to import (rather than just import type) the class constructors in question. * refactor(events): Use event type predicates Simplify several sections of code by using type predicates for type narrowing and thereby avoiding the need for explicit casts. * chore(events): Fix copyright date of recently-added files * chore: Remove unused import
16 KiB
16 KiB