News for hackers. Stuff that matters.
Re:Building a Shop with Sub-Second Page Loads: Lessons Learned by diafygi on Sunday October 23, 2016 @03:19PM (#12774968)
I work in energy, and there's a saying: "The cheapest kwh is one you don't use."

Want to make your website faster? Don't send so much stuff. Removing unnecessary code or content from your site has always had the biggest impact on performance. Unfortunately, it seems that often the people in charge of increasing performance aren't the people who get to choose what has to be on the website.

The Website Obesity Crisis: https://vimeo.com/147806338

    I want to share with you my simple two-step secret to improving the performance of any website.
    
    1. Make sure that the most important elements of the page download and render first.
    
    2. Stop.
Re:Building a Shop with Sub-Second Page Loads: Lessons Learned by blaze33 on Sunday October 23, 2016 @05:02PM (#12775410)
100% this, there is a nice presentation about the bloated web but I couldn't find it now. Remember that performance is a feature: https://blog.codinghorror.com/performance-is-a-feature/

That being said having a fast loading site and being able to serve a spike in load are two different issues (even if having fast loading pages in the first place obviously helps).

Also don't forget that measuring (page size/response times/etc.) is the the first step. You can't optimize what you don't know!

Re:Building a Shop with Sub-Second Page Loads: Lessons Learned by sotojuan on Sunday October 23, 2016 @05:05PM (#12775426)
Here's an easy way to do it:

Want to make your website faster? Use a 3G connection when developing or testing. Chrome Dev Tools make this easy and you can also adjust the latency as needed.

Re:Building a Shop with Sub-Second Page Loads: Lessons Learned by DivineTraube on Sunday October 23, 2016 @05:25PM (#12775507)
That should be done a lot more than it's usual today. Part of "mobile first" should be testing mobile speed.

One problem is of course that mobile networks vary greatly in both latency and bandwidth. A great resource on performance considerations for mobile networks is Ilya Grigoriks open book [1].

[1] https://hpbn.co/mobile-networks/

Re:Building a Shop with Sub-Second Page Loads: Lessons Learned by acqq on Monday October 24, 2016 @03:23AM (#12777171)
Use 2G connection to really feel the pain.

More often than I'd like, I'm trying to read different content "on the go," on the places where the environment blocks the 3G signal and I'm left with the "E" on the iPhone. There are pages that will load (like HN) and the pages that are just "forget it it will never even load."

That's the difference between "accessible" and "shiny but just forget it with the slow internet."

I don't use blockers. It seems that's why they are becoming necessary?

Re:Building a Shop with Sub-Second Page Loads: Lessons Learned by ehnto on Monday October 24, 2016 @01:14AM (#12776854)
The UberEats homepage is 30mb of crisp imagery and fonts. I understand their target market is people on retina screens sitting on the hefty piped intranet of their trendy startup, but 30mb is a complete egress from sensibilities.

There isn't even that much content on the page, it barely goes past the fold.

Re:Building a Shop with Sub-Second Page Loads: Lessons Learned by chetanahuja on Monday October 24, 2016 @02:38AM (#12777034)
Oh good god. I loaded the site with the network console open and found that the page loads 15MB of data before the first picture of food loads up on the page. Horrendous.
Re:Building a Shop with Sub-Second Page Loads: Lessons Learned by cyberferret on Sunday October 23, 2016 @06:08PM (#12775659)
I concur. I did some cursory research the other day, and I noticed that most websites I visit (blogs, shopping sites etc.) now have total asset download sizes that are several times BIGGER than major enterprise software applications that I used to install on my PC 20 years ago. This is just for 'front end' stuff for the browser experience.
Re:Building a Shop with Sub-Second Page Loads: Lessons Learned by smileysteve on Monday October 24, 2016 @12:35AM (#12776779)
This is a strange metric because your phone also has 50x4 the processing power, 20x the ram, and 2g is significantly closer to the Internet connection you would have been lucky to have.
Re:Building a Shop with Sub-Second Page Loads: Lessons Learned by cyberferret on Monday October 24, 2016 @04:34AM (#12777376)
The disparity is that an ERP system that managed the customers, suppliers, production and employees of a multi million dollar business was a smaller executable than a single blog page nowadays that does nothing more than present information on a screen for someone to read.

The ratio of computing power & code size versus the meaningful work done _with_ it seems to be out of kilter somewhat.

Re:Building a Shop with Sub-Second Page Loads: Lessons Learned by DavidWanjiru on Monday October 24, 2016 @06:00AM (#12777664)
It isn't strange, because what is being compared here is the utility of the website and the utility of the ERP. The amount of work (and, subjective though it is, the value of that work) done vis a vis the number of MBs each occupies.
Re:Building a Shop with Sub-Second Page Loads: Lessons Learned by inimino on Monday October 24, 2016 @02:52AM (#12777086)
Just because it's there doesn't mean you have to use it. That's why the user experience doesn't get any faster.
Re:Building a Shop with Sub-Second Page Loads: Lessons Learned by draw_down on Monday October 24, 2016 @02:19AM (#12776994)
This reminds me of the joke where it's like "how to draw a face" or whatever, where step 1 is draw the outline, and step two is do the rest.

In other words, the devil is in the details of how to accomplish #1. It is pithy though, I'll give you that.

Re:Building a Shop with Sub-Second Page Loads: Lessons Learned by huxley on Monday October 24, 2016 @06:08AM (#12777688)
Monty Python's "How to Do It" skit:

https://www.youtube.com/watch?v=tNfGyIW7aHM

"... this week on 'How to Do It' we're going to learn how to play the flute, how to split the atom, how to construct box girder bridges and how to irrigate the Sahara and make vast new areas cultivatable, but first, here's Jackie to tell you how to rid the world of all known diseases."

How to play the flute: "Now, how to play the flute. (picking up a flute) Well you blow in one end and move your fingers up and down the outside."

Re:Building a Shop with Sub-Second Page Loads: Lessons Learned by test1235 on Monday October 24, 2016 @04:43AM (#12777405)
Re:Building a Shop with Sub-Second Page Loads: Lessons Learned by z3t4 on Monday October 24, 2016 @03:47AM (#12777237)
Always let the content have the highest priority when designing a web page.