motionModule
. This returned object contains all of the mixin behaviors as properties of the object.
The advantage of the module pattern is that all of the motion behaviors can be packaged into a single object that can then be used by other parts of your code. Here is an example using it:
```js
motionModule.glideMixin(duck);
duck.glide();
```
funModule
to wrap the two mixins isCuteMixin
and singMixin
. funModule
should return an object.
funModule
should be defined and return an object.
testString: assert(typeof funModule === "object");
- text: funModule.isCuteMixin
should access a function.
testString: assert(typeof funModule.isCuteMixin === "function");
- text: funModule.singMixin
should access a function.
testString: assert(typeof funModule.singMixin === "function");
```