GithubHelp home page GithubHelp logo

Comments (7)

TkDodo avatar TkDodo commented on May 11, 2024 1

It’s a good idea - i think we could just use the ramda one as a baseline, right?

from remeda.

lstkz avatar lstkz commented on May 11, 2024 1

Tree shaking is supported by default. I think we don't need any plugins.

from remeda.

TkDodo avatar TkDodo commented on May 11, 2024 1

I would also see it as a non-goal for now. If someone wants to create a separate babel-plugin repo, they can do so.

from remeda.

TkDodo avatar TkDodo commented on May 11, 2024

depends on your bundler I'd say? some don't support tree-shaking (like parcel v1.0), and it would help to transform the imports there. I am currently enforcing this manually with an eslint rule :)

from remeda.

lstkz avatar lstkz commented on May 11, 2024

@TkDodo https://medium.com/@devongovett/parcel-v1-9-0-tree-shaking-2x-faster-watcher-and-more-87f2e1a70f79
I did only a quick research. Based on the above article, tree shaking is supported in Parcel, and this news is almost 3 years.

from remeda.

TkDodo avatar TkDodo commented on May 11, 2024

@lstkz it was just an example, and parcel has a --experimental-scope-hoisting flag to enable treeshaking, so it's still "experimental". It will be on per default in v2, but there are still many issues with it, and v2 is in alpha stage.

from remeda.

Bessonov avatar Bessonov commented on May 11, 2024

I'm not sure that a such plugin is a win for the community. In fact, I see it as a loss, if maintained by remeda team, because:

  1. It takes time and energy from the core functionalities, which are THE value of remeda.
  2. It's a waste of time, if every library implements a babel plugin instead of solving it in the right place, for example bundler. If some bundlers doesn't have tree-shaking, then it's still just matter of time. I can't imagine using a bundler without tree-shaking support or some pre/post-processing step for ALL libraries, not only through plugins for some of them.
  3. I didn't used babel for years, at least not directly (for example with CRA). Therefore I'm not sure, that a tool-specific solution helps the community. If snowpack resolves some problems with monorepos, then I would like to move from webpack + ts-loader to snowpack + tsc.

from remeda.

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.