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

Runtime detection of duplicate module definitions #7

Open
jasonmcaffee opened this issue Nov 27, 2013 · 0 comments
Open

Runtime detection of duplicate module definitions #7

jasonmcaffee opened this issue Nov 27, 2013 · 0 comments

Comments

@jasonmcaffee
Copy link
Owner

if a module is defined twice during runtime, there can be issues, so provide detection.

var context = {};
context.moduleA = function(moduleB){}
context.moduleA = function(){}

we can probably facilitate this with getter setters or observers.
https://developer.mozilla.org/en-US/docs/Web/JavaScript/Guide/Working_with_Objects#Defining_getters_and_setters

modulus.init({
    _defineContextSetter:function(){
         //by default use native. if devs want to polyfill, they can override this function.
    }
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant