![]() ![]() (From JavaScript for impatient programmers (beta): You can use a handy trick to change object properties with Object Rest/Spread Properties for ECMAScript. Often, object literals define the state of your program (Objects-as-records).Īnd state is one of the mutable parts of your program. It is usually better to use Maps as dictionaries than objects. ĭictionaries: Objects-as-dictionaries have a variable number of properties, whose keys are not known at development time. Records: Objects-as-records have a fixed number of properties, whose keys are known at development time. (From JavaScript for impatient programmers (beta) by Axel Rauschmeyer): Objects were both used as records and as dictionaries. In the past, Javascript only had objects but no maps. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |