I found very useful to have an ability to pass objects with own toString() method to classNames function.
ClassNames makes checking is argument type a string, but doesn't check that it is an object with toString() method that returns string different from "[object Object]"
This checking can allow to combine a few different methods of generation class names, that are useful for libraries that took className from arguments/properties, and pass to classNames function together with own class names.
I found very useful to have an ability to pass objects with own
toString()method to classNames function.ClassNames makes checking is argument type a string, but doesn't check that it is an object with
toString()method that returns string different from"[object Object]"This checking can allow to combine a few different methods of generation class names, that are useful for libraries that took className from arguments/properties, and pass to classNames function together with own class names.