Giter Site home page Giter Site logo

Comments (7)

pastelsky avatar pastelsky commented on July 26, 2024 3

I've added supports for indexing the sideEffects field for all new package searches. Will add support for surfacing this in the UI when webpack@4 becomes stable.

from bundlephobia.

pastelsky avatar pastelsky commented on July 26, 2024 1

Hi @TheLarkInn. Thanks for writing in. What kind of improvements in size does one generally see when using a sideEffects:true package versus otherwise? Also, which webpack versions support this at the moment?

from bundlephobia.

TheLarkInn avatar TheLarkInn commented on July 26, 2024

Potentially could add the annotation here:

bundlephobia/index.js

Lines 316 to 324 in d8202a9

const body = {
error: {
code: 'MissingDependencyError',
message: `This package (or this version) uses ${missingModules}, ` +
`but does not specify ${missingModules.length > 1 ? 'them' :
'it' }<br /> either as a dependency or a peer dependency`,
details: err,
},
}

from bundlephobia.

TheLarkInn avatar TheLarkInn commented on July 26, 2024

Hi there! The sizes can be incredibly significant. With lodash-es, a single import with sideEffects: false now in their package.json takes a 60kb hit to 1-2kb. However not every library will exhibit this behavior. Also it will be as of webpack 4 and on.

from bundlephobia.

pastelsky avatar pastelsky commented on July 26, 2024

With lodash-es, a single import with sideEffects: false now in their package.json takes a 60kb hit to 1-2kb

Does the difference hold in addition to the existing way of treeshaking using jsnext:main / module fields? i.e.

from bundlephobia.

machineloop avatar machineloop commented on July 26, 2024

I believe Wepback@4 has been released, is this available?

from bundlephobia.

pastelsky avatar pastelsky commented on July 26, 2024

This is available in the quick info bar just below the search input. 🎊

from bundlephobia.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.