Hi Raynos,

Very strong words ;-) That said, it is interesting to hear your
opinions!

I originally started with a simple extend paradigm, but as I pushed
the concepts further and relied on them more, things like cleanup
became important. For example, if I registered Backbone.Events in a  a
mixin, I wanted to make sure they got cleaned up when the object's
lifecycle was complete...now is it just a simple Mixin.out(object,
'MixinName') or Mixin.out(object) to remove all of them.

As for the OO comment, I look at this more as aspect-oriented
programming. You are able to package up smaller aspects of your
functionality and mix and match as you want, even dynamically (both
adding and removing functionality), on the fly.

As for bloat and confusion, it would be great to get some concrete
pointers on how to improve the readability and how to simplify...I am
still coming to grips with best practices in Javascript and
Coffeescript...they are so flexible, they I sometimes feel like I am
inventing new implementation patterns each time I tackle a problem.

I'm going to write a sample of how to make a mixin from scratch with
instance data since I realized that my examples don't cover that (but
the tests do).

Cheers,

Kevin

On Oct 11, 12:16 pm, Raynos <rayn...@gmail.com> wrote:
> I've tried looking at the source code. It looks confusing and bloated and it
> appears like your writing an OO system on top of javascript.
>
> It simply looks like overkill
>
> A mixin shouldn't be any more then `Object.extend(o, mixin)`

-- 
To view archived discussions from the original JSMentors Mailman list: 
http://www.mail-archive.com/jsmentors@jsmentors.com/

To search via a non-Google archive, visit here: 
http://www.mail-archive.com/jsmentors@googlegroups.com/

To unsubscribe from this group, send email to
jsmentors+unsubscr...@googlegroups.com

Reply via email to