question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

import cost is too much

See original GitHub issue

I am using extension ‘import-cost’ in VSCode and it shows me import cost below:

import Button from 'material-ui/Button'; is 36.3K gzipped VS import Button2 from 'muicss/lib/react/button'; is 4K gzipped

I just simply compare these 2 UI framework and result is just a button! Why size of material-ui is 9x of muicss?

“material-ui”: “^1.0.0-beta.22”, “muicss”: “^0.9.30”,

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Reactions:4
  • Comments:13 (12 by maintainers)

github_iconTop GitHub Comments

2reactions
mbrookescommented, Dec 5, 2017

20 kB gzip comes from JSS,

A one-time cost though, right? Unless you only use one Button and no other components.

Partly it’s also a tradeoff for having a combined flat, raised and FAB in one component.

1reaction
oliviertassinaricommented, Dec 7, 2017

I have found an interesting leverage to improve the story here:

  • Removing flow Props from the /src
  • Migrating the class components to functions. Transpiling a single class introduce 1.8 kB non gzipped.
  • Using explicit propTypes over generated one. The current propTypes generation situation is pretty bad (I don’t know when the regression was introduced, but it was working with beta.16). They are no linked (no runtime checks 😱 ) nor removed from the production code (dead code 🐳, I think it never worked with flow).
Read more comments on GitHub >

github_iconTop Results From Across the Web

Import Tariffs & Fees Overview and Resources
Tariffs and taxes increase the cost of your product to the foreign buyer and may affect your competitiveness in the market. So knowing...
Read more >
How to Save on Import Duties: 7 Money-Saving Tips - OPAS
With taxes and duties, importing goods can become very expensive. Learn how to reduce the cost of import duties with these seven money-saving...
Read more >
10 import tax and duty mistakes you can't afford to make
These costs are not always trivial; for instance, when shipping a car to Singapore, duties, special fees, and import tax can cost tens...
Read more >
Duty, Taxes and other Fees required to import goods into the ...
The fee is based on the value of the merchandise being imported, not including duty, freight, and insurance charges.
Read more >
Legal Ways to Minimize or Avoid Import Duties - wikiHow
1. Include duties in the price so customers don't have to pay them later. Retail customers don't like surprises. If you use an...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found