You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Consider importing the function directly for better code-splitting (this probably won't reduce the predicted size on bundlephobia, but may reduce final bundle size for projects with tree-shaking)
const semverGte = require('semver/functions/gte')
Or even better, compare version by hand and remove semver from package.json :)
Not sure if this is high-prio as it's possible the above file is already tree-shaken in most projects, I haven't looked where that file is actually used
The text was updated successfully, but these errors were encountered:
brendanmc6
changed the title
Bundle Size: consider importing semverGte directly, or remove semver altogether
@safe-apps-sdk - bundle size - consider importing semverGte directly, or remove semver altogether
May 8, 2021
Semver makes up 58% of this javascript bundle, according to bundlephobia.
Semver is only used on one line:
https://github.com/gnosis/safe-apps-sdk/blob/9568ed238b584251ac9ee5e21c5cbbaf1693fc9f/packages/safe-apps-sdk/src/communication/index.ts
Consider importing the function directly for better code-splitting (this probably won't reduce the predicted size on bundlephobia, but may reduce final bundle size for projects with tree-shaking)
Or even better, compare version by hand and remove semver from
package.json
:)Not sure if this is high-prio as it's possible the above file is already tree-shaken in most projects, I haven't looked where that file is actually used
The text was updated successfully, but these errors were encountered: