> I love how you can move a function definition from a class to outside of a class or even into an object “literal” without breaking syntax.
Actually more important is, that you can move them into a class of object literal. And way more languages should be designed with that in mind.
> And same with variables, you can restructure it from a global into a class property or as a property of an object literal.
This allows you to just start to write code as a script, and then effortlessly partition it into functions, classes and files as need arises.
Another thing I'd like to see more in languages is keeping consistent interface across various data structures.
You should be able to swap out array for a set, hash table, or even something weird without rewriting half of your code that touches it.