Closed dminkovsky closed 9 years ago
also been looking at this, while trying to implement a circular dependency - seems that collections
is almost the same in terms of instantiation as children, except for where the instance is stored, and that it doesn't bubble events.
Hey, thanks for using ampersand and filing this. It's now been fixed! :tada: http://ampersandjs.com/docs#ampersand-state-collections
I was looking at
children
docs and wondered if state objects support collections too. I looked for a subsection called "collections", and to my disappointment didn't find one.But then, lo and behold, the section on
children
mentionscollections
. I looked in the code and yup,extend()
examines acollections
key that is then passed to_initCollections()
.Should this be documented? If yes, I'd volunteer for this but I'm about an hour in to working with Ampersand.