Echo JS 0.11.0

<~>
TroyTae 1603 days ago. link parent 1 point
I removed supporting object intentionally.
There are two reason:

1. You can use expression instead of object.
ex) true && 'class1' or false && 'class1'

2. I failed to find the reason that must use object.
Array has many method and that is very useful.
But I cannot sure object has more advantages than expression.

If you know some good use case, please tell me!!
I want to know it :)

Replies

tracker1 1602 days ago. link 2 points
Two biggest reasons, I like the syntax, and using object de/structuring...

    export default ({ foo, children }) => (
      <div className={classNames(
        'some-component', 
        { foo }
      )}>
        {children}
      </div>
    );
TroyTae 1600 days ago. link 1 point
Thank you!
I'll try to think about it again :)