3 ms·
>*"JavaScript bloat is more real today than it ever was. Sites continuously get bigger as more (often redundant) libraries are thrown to solve new problems." V
by flavio81 9y ago
>*"JavaScript bloat is more real today than it ever was. Sites continuously get bigger as more (often redundant) libraries are thrown to solve new problems."
Very true, pointed criticism, but i'm afraid part of the answer is avoiding npm altogether.
- nulagrithom 9y agoHow does avoiding the use of a package manager fix bloat? Or do you mean to say everyone should be writing vanilla JS with zero dependencies?
- abritinthebay 9y agoNot true. A massive majority of that code you download is from 3rd parties. Ads, tracking, analytics, Instagram & Facebook embeds, etc... Now you can suggest that we should move to not having any of these but from a business perspective that’s... very hard. Trimming is possible, of course, but the reality is that npm is not the problem- sites were bloated with JS before it came along.
- busterarm 9y agoMy company's entire business revolves around embedding tracking and analytics JS on our page and serving it to people and all of those plugins combined are still dwarfed by something like React or Angular by a factor of 2x. The problem ends up being when you're embedding this stuff and the provider has their own dependencies they're loading. Hubspot's embedded web forms pulls in an entire React framework. Mess. If you're serious about doing this stuff, you include the bare minimum JS possible (GA/GTM, usually), store GUIDs in your request logs and put that into your analytics data pipeline. And keep telling the Google rep to take a hike when they put pressure on you to use AMP.
- abritinthebay 9y agoSure, I’ll believe you and not what the browser reports. AMP may be bullshit but it means a 5-10x increase in traffic so... again, missing the business case.
- busterarm 9y agoIf eyeballs is what your metric is, that might be fine, but our traffic needs to convert into something (in our case a form fill, in others a sale). AMP dropped our conversion rate through the floor. And if you want analytics & tracking, you're very limited or you have to use all/only google services. It's a great way for google to build a captive market of content providers, but once everyone is serving AMP pages, the benefit to brands (SERP) is gone.
- abritinthebay 9y agoConversely - we see decent conversion rates (at worst no difference to regular) so... maybe it’s your approach? I hate AMP with a passion but your specific objection hasn’t been true for us.