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

Support direct embed into HTML #13

Open
bryanbraun opened this issue Jul 4, 2018 · 1 comment · May be fixed by #14
Open

Support direct embed into HTML #13

bryanbraun opened this issue Jul 4, 2018 · 1 comment · May be fixed by #14

Comments

@bryanbraun
Copy link

I noticed that this library is set up to support a commonJS interface (like Node and Webpack). It would be great if it also supported being direct embedded into HTML. Currently, attempting that results in errors like: Uncaught ReferenceError: exports is not defined

We could use something like returnExports from UMD which lets a module work with Node (CommonJS), AMD (e.g. RequireJS) and browser globals. Or we could simplify it by not supporting AMD.

Love this library and how simple it is!

@bryanbraun bryanbraun changed the title Support direct embed into HTML. Support direct embed into HTML Jul 4, 2018
@bryanbraun
Copy link
Author

bryanbraun commented Jul 4, 2018

Oh! It looks like you already have a babel plugin for doing this in your dev task. We just need to add it to your build task to ensure it gets in the production build. I can do a PR for that.

bryanbraun added a commit to bryanbraun/dom-confetti that referenced this issue Jul 4, 2018
bryanbraun added a commit to bryanbraun/dom-confetti that referenced this issue Jul 4, 2018
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

Successfully merging a pull request may close this issue.

1 participant