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

Brunch does not wrap the entire project in a namespace function #1

Open
monokrome opened this issue Oct 22, 2012 · 2 comments
Open

Comments

@monokrome
Copy link
Owner

This project needs to be in it's own namespace, but brunch does not wrap output in a namespace if you aren't using CommonJS modules. If you are using them, then it creates a separate namespace for each file as expected by the CommonJS require method.

@peterwilli
Copy link

@monokrome I just made a plugin that does this. I used it for my Javascript SDK in combination with brunch-for-libs. Maybe we can include it by default if you like. See: https://github.com/LogAndRoll/singlewrap-brunch

@peterwilli
Copy link

Didnt got time yet to add a good documentation but it's pretty simple to use. Upon inclusion it will wrap all a joined / minified JS file in 1 self executing function, with options to customize.

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

2 participants