Convopage
See the entire conversation
Jake Archibald
@jaffathecake
I see some great fast PWAs launching, but it's difficult to know what to do with the other sites that launch with 10s+ of CPU before render…
105 replies and sub-replies as of Apr 02 2017
Jake Archibald
@jaffathecake
…demos of slowness are easy to dismiss as "not real", shaming is hard on individuals, quietly fixing each site doesn't scale…
Jake Archibald
@jaffathecake
…but our industry is on the line here. A web of slow unusable apps suggests the web is incapable of being an app platform…
Jake Archibald
@jaffathecake
…the "money people" need to see fast sites and think "I need that", and see slow sites and think "that's a development failure".
Arjun
@adgad
Making a direct link between performance and revenue/business metrics helps here, a la
engineroom.ft.com/2016/04/04/a-f…
Linus Lee
@thesephist
In the case of one of my projects at work, it's a data-heavy app with frequently updated data that loads MBs of JSON on load..
Linus Lee
@thesephist
... a huge part of our initial CPU run is serializing data + render, which is difficult to efficiently offload to server-side.
Jake Archibald
@jaffathecake
a pattern like
jakearchibald.com/2016/fun-hacks…
would work wonders here
Fun hacks for faster content
Using iframes and document.write to improve performance of content loading.
jakearchibald.com
matthewcp
@matthewcp
Agreed. The question is why is it so easy to make slow websites? I don't think it's an experience thing.
matthewcp
@matthewcp
My theory is that the web has stopped trying to be a dev environment, so devs seek external tools.
matthewcp
@matthewcp
This creates a disconnect between the thing they work with (their tools) and the thing the deploy.
Jake Archibald
@jaffathecake
some frameworks are slow by default, and the default gets shipped due to time. Sometimes this is as simple as a "dev mode"
matthewcp
@matthewcp
The web is slow by default. Blocking scripts, blocking stylesheets. No streaming support in most server frameworks, etc.
matthewcp
@matthewcp
I wish there were a fast mode meta tag that banned all slow practices. A "use strict" for HTML.
Jake Archibald
@jaffathecake
I guess this is AMP's aim
Erik Isaksen
@eisaksen
I answered w/out reading this ...doh
Erik Isaksen
@eisaksen
AMP actually is kinda like that. It forces you to into a 'strict' way of coding in xchangd for speed
Joel Zipkin
@hipsterzipster
Library bloat + no bundle splitting are major issues. Seen 60+ node mods on a big React app. We gotta change or the web loses
Jake Archibald
@jaffathecake
totally agree
Nicolas
@necolas
They should see slow sites/apps and think "that's what happens when money and product people don't value speed"
Jake Archibald
@jaffathecake
all these managers fancy themselves as the next Steve Jobs, but totally miss that the iphone lacked in features but won on quality
Ben
@sangster
"but what if we could get companies to give us millions of dollars to automatically add custom emoji after hashtags"
joshduck
@joshduck
Instead of trying to tell people "no", work to make what's popular faster. Have you looked at React Fiber?
Jake Archibald
@jaffathecake
your comment seems ignorant of the articles/talks/features/specs I work on
joshduck
@joshduck
That came across as harsh, sorry. I do appreciate and admire your work, especially on Service Workers.
Jake Archibald
@jaffathecake
I don't bet too much on a single framework, I try and stick to general stuff like
Fun hacks for faster content
Using iframes and document.write to improve performance of content loading.
jakearchibald.com
joshduck
@joshduck
Can be strategic. Project with Google backing can influence ecosystem. See: create-react-app killing boilerplate projects.
Jake Archibald
@jaffathecake
huge value in driving change in tooling. I fought for changes like
github.com/facebook/react…
.
Explore encouraging users to not ship DEV mode to production · Issue #8784 · facebook/react
Do you want to request a feature or report a bug? Feature What is the current behavior? Developers meaning to do the right thing will often accidentally ship DEV mode to production rather than PROD...
github.com
joshduck
@joshduck
Reprasing: IMO future of web perf is in embracing and improving abstractions in user space. PWA, SW, ignition all good steps.
Ben Lesh
@BenLesh
I think the "tech people" need to see fast web apps. The "money people" tend to delegate decisions on tech to be used
Ben Lesh
@BenLesh
often it's tech folks that think they need to go native.
Vivian Cromwell
@viviancromwell
most ppl start the biz with:where to acquire users,how many users through various funnels,what is the most effective funnels.
Vivian Cromwell
@viviancromwell
outside the small browser vendors/js community, very few think about web vs native or fast speed.
Jake Archibald
@jaffathecake
yeah, that's what I was thinking of when I posted
Jake Archibald
@jaffathecake
all these managers fancy themselves as the next Steve Jobs, but totally miss that the iphone lacked in features but won on quality
Vivian Cromwell
@viviancromwell
sure there are crazy ppl, but most founders I have met are very passionate, so genuine wanting to solve a problem.
Jake Archibald
@jaffathecake
I haven't met many that value quality over quantity (of features/users)
Vivian Cromwell
@viviancromwell
not always so black and white. the best article written is
goo.gl/9yigw4
by
@owencm
, focused on users with empathy
The surprising tradeoff at the center of the question whether to build a Native or Web App
The choice to build a native app over a website is often made because apps “feel” so much nicer than web sites and that “they’re the future…
medium.com
Owen Campbell-Moore
@owencm
Adam Solove
@asolove
Isn't the problem primarily non-technical? Organizations that need plain hypertext sites but try to have "apps" to be cool?
Adam Solove
@asolove
The solution to the 90's "my nephew built it" crap sites was to professionalize the industry and say no to stakeholders.
Jaume Sanchez Elias
@thespite
not shaming, but being open about the problems of these sites and pointing at fixes that might help all devs is a good option
Jake Archibald
@jaffathecake
when we point to a slow site it's seen as shaming by some
Jaume Sanchez Elias
@thespite
if it's just the one site, may be. but if it's terribly slow it might be a sign that they need help. depends on the attitude?
Jake Archibald
@jaffathecake
right, but fixing the web site by site doesn't scale
Jaume Sanchez Elias
@thespite
it doesn't. but the more egregious cases? if there's a lot of issues with framework n or bundler m, everyone can learn from it
Jaume Sanchez Elias
@thespite
i'm thinking how game development and graohics have evolved, for instance, and there's no "how's it made" readily available
Stuart Robson
@StuRobson
trying, building an 'app' based on web tech. from the start (wrapped in Electron) looking at all the 'best practices' rn
overflow: heydon
@heydonworks
The performance problem is less to do with lack of tooling/tweaking and more to do with fundamental bad design process.
zac 🤹
@zaccolley
you saying if you designed for simplicity you wouldnt need heavy libraries etc in the first place?
overflow: heydon
@heydonworks
Yes. Or leveraged browser/HTML behavior over redundant scripting. Lots of possibilities.
Rahul
@Rahul
Well, Google already scaled something like that quietly with Operation Rosehub. Could do one for PWAs but rather than github, crawl sites ;)
patrick h. lauke
@patrick_h_lauke
lots of subtweeting?
jenngleheimer schiff
@jennschiffer
I imagine browser vendor task force teams, like Mozilla has the
@webcompat
team for compat, would help
Jake Archibald
@jaffathecake
we already have dev rel writing articles, speaking about good/bad examples and reasons, getting changes into tooling…
Jake Archibald
@jaffathecake
…changing/expanding the platform at a spec level… are we missing anything?
webcompat.com
@webcompat
the rusty Web, aka that sites can age. Most of these sites are exactly like the Java/Flash app of the past
@jennschiffer
jenngleheimer schiff
@jennschiffer
yeahhhhh I knowwww I mean
@webcompat
contacts the teams of devs whose sites are broken
Jake Archibald
@jaffathecake
we do that too 😀. Difficult to scale though
Steve Workman
@steveworkman
add it to
@____lighthouse
-
@patmeenan
put that into WebPageTest today
Patrick Meenan
@patmeenan
Time to Interactive is the relevant metric and was added a few weeks ago
Patrick Meenan
@patmeenan
getting people to care or focus on it is the hard part
jenngleheimer schiff
@jennschiffer
if you partner with a company and make a big deal their competitors may be like 👀👀👀
jenngleheimer schiff
@jennschiffer
because the only way higher ups would care is if it involves 💸💵💴💶💷💰
Steve Workman
@steveworkman
the ranking boost sold my boss on HTTPS - advertise that first paint affects it
Steve Workman
@steveworkman
I'm pretty sure it has a small effect right now, so make a noise!
Jake Archibald
@jaffathecake
well, this is what made AMP a success, although I feel 😕 about it
Jake Archibald
@jaffathecake
yeah, this is the big problem 😞
Andy Davies
@AndyDavies
We need non-techies to talk about their successes at non-techie conferences etc.
Guillaume Rossolini
@g_rossolini
I'd love for it to be in a requestable API, preferably pagespeed or WPT
Patrick Meenan
@patmeenan
It's in WPT API as long as you use Chrome and enable timeline capture
Patrick Meenan
@patmeenan
Everything in the WPT UI is available in the API (UI uses it itself)
Guillaume Rossolini
@g_rossolini
oh I was confused with lighthouse. Thanks
jenngleheimer schiff
@jennschiffer
unsubscribe lol
Patrick Meenan
@patmeenan
FWIW, lighthouse is also available through the API - lighthouse=1
Ernest Adams
@ElopeToCT
What are PWAs? TIA!
Magbic Aleman
@magbicaleman
im thinking
Web | Google Developers
(no description)
developers.google.com
Rich Danielson
@richdanielson
Could you point to examples of each?
Jake Archibald
@jaffathecake
well, that would be shaming right?
flipkart.com
is my go-to example of a great modern web experience.
Online shopping Site: Shop online for mobiles,electronics,fashion & more @ Flipkart
Shop for electronics, apparels & more using our Flipkart app Free shipping & COD.
flipkart.com
Rich Danielson
@richdanielson
Much thanks. We'll look to positive benchmarks, not negative.
вкαя∂εℓℓ
@briankardell
10s+ of *CPU* time? you're saying take out all the network and everything and you have 10s+?
Jake Archibald
@jaffathecake
oh yes
вкαя∂εℓℓ
@briankardell
dm me an example?
вкαя∂εℓℓ
@briankardell
disregard, I missed it. sorry.
Ashley Gullen
@AshleyGullen
help their competitors optimise their sites instead. Then the motivation can be to beat their rivals!
James 🇹🇭
@JamesSLock
we still have yet to implement bundle splitting. We've a 700kb bundle.js 😭 it's in the backlog.
Jake Archibald
@jaffathecake
oof, can any of that be lazy-loaded?
James 🇹🇭
@JamesSLock
yeah, right now hitting /signup will force a full download of the bundle. Can split that by routes so it'll be 150kb...
James 🇹🇭
@JamesSLock
should result in the signup page going from 800kb to 200kb. Just need to find bandwidth.
James 🇹🇭
@JamesSLock
it's been a challenge when everyone is like "loads fast for me" sitting on our 1gbps office internet connection.
Jake Archibald
@jaffathecake
yeah, we've even seen sites that were bigger than a screencast of the site. Glad you're fighting the good fight!
James 🇹🇭
@JamesSLock
new marketing site going live soon. Same design but fixed performance 750ms render. App is a much bigger beast.
James 🇹🇭
@JamesSLock
Them I'm on my 3G UK sim plan in NY capped at 125kbps like... Nope this is not ok.
James 🇹🇭
@JamesSLock
and "everyone has 4G nowadays"
James 🇹🇭
@JamesSLock
then lazy load the rest of the bundle for SPA.
James 🇹🇭
@JamesSLock
currently focused on removing several large NPM librarys in favour of smaller more specific code to reduce bloat overall.
Jake Archibald
@jaffathecake
yeah, I had problems with stuff tree-shaking badly because it was written using module.exports
Jake Archibald
@jaffathecake
200k sounds pretty healthy though. Throw in some server rendering and it'll be 👌
James 🇹🇭
@JamesSLock
SSR is a much harder buy in due to how we wrote the app. Hopefully before the years out though.
Simon Green
@CaptainCodeman
in theory, market forces would make the faster sites more successful and the slower ones be forced to change to compete.
Jake Archibald
@jaffathecake
unless everyone puts minimal effort into the site and builds an app instead
Simon Green
@CaptainCodeman
stats for native app engagement and drop-off are pretty appalling but I see what you mean, we need to compete better with it
Simon Green
@CaptainCodeman
more at a higher decision-making level than at the individual site implementation level
Simon Green
@CaptainCodeman
ironic observation: sites almost guaranteed to be bloated and slow on mobile - mobile phone company web-sites.
Alan Plum
@lnplum
worst offenders I see regularly are ads and CMS backed sites. Not sure how to address that as a frontend dev.
Anshuli Gupta
@anshulix
Their users would respond to them with not using it, I think it will change sooner or later. :)
Tobi Reif
@TobiReif
That sounds like a dichotomy, but there also can be non-PWA web-apps that are fast.