I read the below in a tutorial site and am learning about objects but I didn't understand what they mean.
{Arrays, functions, date, regex, …}, are specialized objects. They have special properties and behaviors than normal objects. But they still are key/value pairs.
I can see that arrays have an index which can be the key and the value of that index makes the pair, but how do functions and dates have key value pairs? I don't really understand how they're objects and not just datatypes like a string or a number?
Can someone explain this in a simple way for me please.