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

Proper UMD export and npm building #30

Open
wants to merge 5 commits into
base: master
Choose a base branch
from

Conversation

jasonkarns
Copy link

Source is a proper CommonJS module.
UMD utility generates the wrapping UMD wrapper and is uglified.
Both of these steps are done via npm's prepare step,
which is run automatically during the pack/publish lifecycle and
during bare installs (ie, when installed as a git-dep).
Sourcemap is also generated to accompany the uglified output.
The built assets are ignored from git (generated assets shouldn't be version controlled).
Npm is instructed to include the appropriate built assets in the package tarball.
Package-lock is added as per npm5.

@jasonkarns
Copy link
Author

jasonkarns commented Dec 12, 2017

Replaces #27. #27 just adds a guard to the window assign. This PR, instead, exposes gator as proper first class CJS module. and builds a distributable using the universal module format: UMD (and does so as part of build, rather than manually including the boilerplate into source)

Also fixes #22

gitignore node_modules (umd) and the built assets.
But instruct npm to include the build assets
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 this pull request may close these issues.

1 participant