
React profiling component to measure the "cost" of rendering - rbanffy
https://github.com/bvaughn/rfcs/blob/profiler/text/0000-profiler.md
======
hinoki
It doesn't look like this gives more information than the built in profiling
tools[0] React already has.

So it looks like an interesting project to learn the component lifecycle and
some React internals, but if you need to make your react apps faster you
should probably use the provided profiling tools.

[0] [https://building.calibreapp.com/debugging-react-
performance-...](https://building.calibreapp.com/debugging-react-performance-
with-react-16-and-chrome-devtools-c90698a522ad)

~~~
ricardobeat
The current debugging tools use the User Timing API, which according to the
post have large overhead, and don’t account for ‘yield’ time when async
rendering is enabled (this is kind of the TL;dr for the whole proposal).

------
TekMol
Everytime a project is reimplemented via react, it's much worse then before. A
recent example is Reddits redesign.

Is using React always bad for the user or are there any examples out there,
not behind a login, that show a good usecase for React?

~~~
allover
Twitter Lite and Airbnb are obvious examples not behind a login.

I'm sure there are countless good examples in this list:
[https://github.com/facebook/react/wiki/Sites-Using-
React](https://github.com/facebook/react/wiki/Sites-Using-React)

But React and other SPA libraries will always excel more for more complex UIs,
those sorts of things tend to be behind logins.

~~~
madeofpalk
The claim that Twitter "Lite" is an improvement is a collective delusion of
the web development community, spread by Google and Twitter PWA evangelists.
By every measure, except 'shininess', it performs worse that both Twitter.com
and the old legacy mobile.twitter.com (which can still be accessed if you set
your user agent to something like a Blackberry).

Even from a warm cache, Twitter Lite takes longer to display your timeline
compared to desktop Twitter. Compared to the legacy mobile twitter site, the
PWA version is 15x slower at showing your timeline [1]

And this is all the while ignoring the UX annoyances of the PWA version. When
loading the timeline, you're presented with about three different loaders, all
flashing about the screen.

[1]:
[https://twitter.com/joshhunt/status/980769162770485249](https://twitter.com/joshhunt/status/980769162770485249)

~~~
untog
Yep, first load is slower. But loads of any click you make are faster. That's
the trade-off.

~~~
madeofpalk
But first load (and repeat loads of the first page you visit) is the only
thing that matters. The primary use case of Twitter is the timeline - if
you've made displaying that slower, you failed to make a faster site. You blew
it.

Of course I know nothing about the complexities of Twitter internally and
technically, but I don't understand how they managed to make it slower than
the Desktop Twitter, and claim that they built a better experience when they
clearly haven't.

\---

Edit: I just did a tiny bit of by-the-eye comparisons between Desktop Twitter
and Twitter Lite, and loading Notifications seems a bit faster on Twitter
Lite. Loading Profile might be the tiniest bit faster on Twitter Lite, but I
suspect there's a lot of DOM jank that slows displaying the next page. Showing
DMs is slower on Twitter Lite compared to Desktop Twitter.

But even so, what does this have to do with the PWAs that Google+Twitter
evangelise? My understanding is that PWAs are all about speeding up the warm-
cache 'first load' [1], and once that's loaded, there's not really much that
the PWA technologies will do for you. Both Desktop Twitter and Twitter Lite
are Single Page Apps that fetch views from API calls - there's nothing
inherently different about Twitter Lite's approach that will make it faster at
that compared to Desktop.

[1]: 'First load' seems to be the wrong name to call this, but unsure of a
better, more concise phrase.

~~~
yzmtf2008
>The primary use case of Twitter is the timeline - if you've made displaying
that slower, you failed to make a faster site. You blew it.

It’s not at all clear this is true. Does explore get a lot of traffic?
Comments? Maybe interactions are more valuebale than pageviews?

What if I’m in the elevator, and I want to check my twitter feed?

Obviously I know none of these things, but those are assumptions I wouldn’t
make easily.

~~~
dmitriid
> Maybe interactions are more valuebale than pageviews?

They are, to Twitter. Twitter is driven by engagement, not by user needs.

