Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Don't require modules to return function #28

Closed
rikschennink opened this issue May 19, 2013 · 1 comment
Closed

Don't require modules to return function #28

rikschennink opened this issue May 19, 2013 · 1 comment

Comments

@rikschennink
Copy link
Owner

Use "new" constructor on Modules that return a function.

When an object is returned this object should have a "load" method which returns another object, this object should have an unload method and can be the same object as the object having the load method.

var exports = {
    load:function(element,options) {
         // do stuff
         return exports;
    },
    unload:function() {
         // clean up
    }
};
return exports;
@rikschennink
Copy link
Owner Author

this is now possible

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant