Skip to content

recude package sizes #87

Description

@beeequeue

installing @codspeed/core currently takes up 5MB of space on disk, which can be reduced quite a bit

https://npmgraph.js.org/?q=@codspeed/core

  • axios can be replaced with just fetch, or if mroe complex utilities are needed ky or xior can also work
    • this alone would reduce the install size by 3MB
  • find-up can be replaced with empathic, which is smaller and faster
  • the packages is currently publishing both CJS and ESM files, along with source maps for both the code and types.
    • node 20.12+ supports require(esm), so you could drop the CJS build if you drop support for versions below it
      • this would remove 0.5MB
    • source maps are generally not necessary if you don't minify the packaged code, and not-minified code without source maps has the best size-to-benefit ratio out of the possibilities
      • this would remove 1MB

all in all i think core could be brought down to about 1/9th of the original size

i would be up for helping with this if you want!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions