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

Publish ESM + CJS + UMD modules #62

Merged
merged 3 commits into from
Jun 13, 2017
Merged

Publish ESM + CJS + UMD modules #62

merged 3 commits into from
Jun 13, 2017

Conversation

TehShrike
Copy link
Owner

Fixes #58

Drops the hardcoded UMD pattern, allowing bundlers to avoid grabbing it.

Moves the isMergeableObject function out to its own module, allowing other libraries to use the same algorithm for iterating over objects (see #61).

Also fixed some test jank by removing unused variables and adding a missing var

TehShrike added 2 commits May 22, 2017 16:04
Fixes #58

Drops the hardcoded UMD pattern, allowing bundlers to avoid grabbing it.

Moves the isMergeableObject function out to its own module, allowing other libraries to use the same algorithm for iterating over objects (see #61).
Removing unused variables and adding a missing var
@macdja38
Copy link
Collaborator

The is-mergable-object repository seems to be missing a license? It should probably be under:
https://github.com/KyleAMathews/deepmerge/blob/master/license.txt
Also it seems to calculate Object.prototype.toString.call(val) twice, this could possibly be made faster by storing the result in a variable?

@TehShrike
Copy link
Owner Author

I changed the is-mergeable-object license to MIT to match deepmerge, and broke those toString calls out to a function.

@TehShrike TehShrike merged commit f224417 into TehShrike:master Jun 13, 2017
@macdja38
Copy link
Collaborator

My problem was not that the code was write twice... it was that it was run twice... breaking them out into a function call does not reduce the number of times they are run, it just ads the overhead of calling a function to them.

@TehShrike
Copy link
Owner Author

oh duh, lol. I'll fix that

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.

loading with requirejs cause error
2 participants