Git Product home page Git Product logo

Comments (4)

giogonzo avatar giogonzo commented on September 26, 2024

Hi @eek , the number seems off to me. Are you actually minifying your production bundle?

tcomb + tcomb-react should amount to about 14Kb when minified, and less than 4Kb when minified and gzipped

from react-autosize-textarea.

eek avatar eek commented on September 26, 2024

That's an approximation by webpack (with minifying on) so it might be off.

I don't understand the added value that brings to a library that is 3.7kb. I mean, what's the reason to have something 14 times larger just to check props when React has something built in that's great.

export const Props = {
  rows: t.maybe(t.Integer),
  maxRows: t.maybe(t.Integer),
  onResize: t.maybe(t.Function)
};

I can do a pull request to fix this if that's ok with you guys as well.

from react-autosize-textarea.

giogonzo avatar giogonzo commented on September 26, 2024

Yes, I fully agree.
Didn't mean to be the nitpicker here, just wanted to add exact numbers to this conversation :) So here they are (minified): react-autosize-textarea 4k, autosize 3.5k, tcomb 12.5k, tcomb-validation 4k

We've been using tcomb up to now mostly for parity with other internal projects and historic reasons.
In our internal projects we are already paying the tcomb additional bytes so it hasn't been an issue for us.

We'll gladly accept a PR for this, but it will probably require a few changes cross-repo so it might not be merged & released right away. In any case I'll leave the final word to @FrancescoCioria

from react-autosize-textarea.

FrancescoCioria avatar FrancescoCioria commented on September 26, 2024

Yes, we can remove it :)
@eek can you open a PR for us?

from react-autosize-textarea.

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.