I want to add my own methods to a few Dart Classes
My attempt to simply 'Extend' the Map class fails because List is an interface and cannot be extended but must be implemented. The goal was simply to add a few methods on top of some existing class such as: List.add_unique(item) where I only want to append if the item does not already exist. This can be done nicely by and-ing the append !=null logic with List.indexOf(item) != -1 (where -1 is notFound). This would be a good and easy to understand example? But, how to accomplish this in the shortest, least overall overhead sort of way? I think I would be OK with loose typing - at least to start