These two methods are different. The first one is declared as a property, so it Contravariance, while the second one Bivariance. For type safety, the first approach is better.
TS Method Type Signature
Creator
Creator
Seonglae ChoCreated
Created
2021 Aug 17 3:57Editor
Editor
Seonglae ChoEdited
Edited
2025 Oct 16 12:44Refs
