Closed troutowicz closed 9 years ago
Thoughts on limiting react-stampit's initializers
property to one function (rename to init
in this case) instead of an array of functions? Would there ever be a time when an array of initializers would make sense in React?
I like this. I can't think of any time that we would end up with multiple initializers on a React component without composing them, but since one could provide a function instead of an array and it would still work, I'm not sure it should be restricted.
With other names matching (e.g. refs
and methods
), should initializers
be init
to match?
Clarification: I meant I think initializers
should be init
even if it is an array, since in stampit-land init
can take an array of functions too.
but since one could provide a function instead of an array and it would still work, I'm not sure it should be restricted.
Good point.
With other names matching (e.g. refs and methods), should initializers be init to match?
The reason I used initializers
was to conform with the current stamp specification. I personally like init
more, but \o/.
initializers
in the stamp spec is just the name of the fixed stamp descriptor property. You're free to do whatever you want with helper functions/methods.
Ah, right... I misread the spec.
=)
Issue #31
@ericelliott
.compose
is already present. We do need to to make acompose
util though.