Replace lodash with homemade functions #112
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
I'm not particularly happy of the Tippy + Popper bundle being whopping 32kB and this wrapper package adding 47kB is a joke.
PR demonstrates how you could reduce it's size by replacing
lodash.<module>
dependencies with functions crafted to your needs. It's still enormous, but the change shoved off roughly 20kB. If such replacement is no-no, consider at least replacinglodash.<module>
withlodash-es
, asmapValues
andpickBy
overlaps andlodash-es
is more likely an existing dependency of final app thanlodash.<module>
.For anyone willing to use it now in their webpack process (works for me, no test included / passed):
npm i Aareksio/vue-tippy#fix-module-size