disable
disable( ) : void
Disables the Observer, removing the necessary event listeners and firing the onDisable
callback if the Observer wasn't already disabled.
Details
Disables the Observer, removing the necessary event listeners and firing the onDisable
callback if the Observer wasn't already disabled. If you plan to disable it permanently, use kill()
instead so that it also gets removed from the internal Array and can be made available for garbage collection.