2 ms·
What DSLs are you referring to here? One reason to favor lists over arrays has been that they are immutable. Most of my personal JS array usages have been as d
by bsansouci 9y ago
What DSLs are you referring to here?
One reason to favor lists over arrays has been that they are immutable. Most of my personal JS array usages have been as dynamically sized arrays, because I’ll use .push all over the place. That usecase is the primary reason to use lists instead: it’s much faster to prepend and destructure on lists.
- aaron-lebo 9y agoSomething like Elm's Html module: div [ id "test" ] [ text "stuff" ] vs div [| id "test" |] [| text "stuff" |] If the JS library expects an array (not uncommon), that gets ugly quickly.