Skip to content

Proper UMD export and npm building - #30

Open
jasonkarns wants to merge 5 commits into
ccampbell:masterfrom
jasonkarns:umd
Open

Proper UMD export and npm building#30
jasonkarns wants to merge 5 commits into
ccampbell:masterfrom
jasonkarns:umd

Conversation

@jasonkarns

Copy link
Copy Markdown

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

jasonkarns commented Dec 12, 2017

Copy link
Copy Markdown
Author

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