What is the alternative to maps in polymer Dart 1.

2019-08-07 16:07发布

问题:

I notice in the Polymer Dart issue #569, that the use of maps is discouraged, because they're inefficient. What is (will be) the alternative? I use maps a lot.

回答1:

The original reasoning for the comment about inefficiency no longer applies. Previously the whole map had to be copied to a new JsObject each time it was passed to JS, but that is no longer the case.