[go: up one dir, main page]

Skip to content

Instantly share code, notes, and snippets.

@malchata
Last active May 29, 2021 14:23
Show Gist options
  • Save malchata/e7c4862b77120dc230763ea8f3110c17 to your computer and use it in GitHub Desktop.
Save malchata/e7c4862b77120dc230763ea8f3110c17 to your computer and use it in GitHub Desktop.
React Bias

React Bias

It may seem like a bold suggestion that we as web developers can choose the wrong tools for the job because we tend to be swayed by appeals to popularity or authority, but simple statistics imply just that. For example, React (https://reactjs.org/) is a JavaScript framework that emphasizes componentization and simplified state management. It enjoys strong advocacy from a vocal and dedicated userbase within the developer community.

Despite React’s apparent popularity, however, The HTTP Archive observed in 2020 that React only accounted for 4% of all libraries in use across the 7.56 million origins it analyzed (https://almanac.httparchive.org/en/2020/javascript#libraries).

For context, The State of JS 2020 Survey (https://2020.stateofjs.com/en-US/), which surveyed roughly 23,765 respondents, offers the following statistics:

  • 70.8% of respondents identified as white.
  • 91.1% identified as male, whereas 5.8% identified as female and 0.9% identified as non-binary/third gender.
  • 97.6% assessed their proficiency in JavaScript at either an intermediate (22.7%), advanced (22.3%), or expert level (52.6%). Just 2.3% self-reported their proficiency at a beginner level.
  • 72.5% of respondents reported an 87.5% satisfaction rate with React.

The juxtaposition of The HTTP Archive’s analysis and The State of JS 2020 Survey results suggest that a disproportionately small—yet exceedingly vocal minority—of white male developers advocate strongly for React, and by extension, a development experience that favors thick client/thin server architectures which are given to poor performance in adverse conditions. Such conditions are less likely to be experienced by white male developers themselves, therefore reaffirming and reflecting their own biases in their work.

@timseverien
Copy link
timseverien commented Jan 18, 2021

White male here with a slight disgust towards React and in particular its toxic community here.

Although I agree with the sentiment, and React-fanboyism is definitely a problem, I also think it’s easy to misinterpret the data and arrive at skewed conclusions.

Of the >7 million sites in the dataset, I highly doubt all of them are relatively new. In other words, I presume many sites predate React. To get a better perspective, we should only consider sites published after React gained popularity. I suspect we’ll see similar results; the React community is more vocal than it actually being used, but odds are the library will account for more than 4%.


Edit: English

@viki53
Copy link
viki53 commented Jan 18, 2021

@timseverien Looking at the Methodology (https://almanac.httparchive.org/en/2020/methodology) it seems like they're looking at recent crawling data, which may include some older websites but also quite a lot of recent pages.

An other bias though is private apps. React and other frameworks being used for apps more than just websites, these contents aren't always accessible to crawlers, which makes real-world stats difficult to get.

@timseverien
Copy link

@timseverien Looking at the Methodology (https://almanac.httparchive.org/en/2020/methodology) it seems like they're looking at recent crawling data, which may include some older websites but also quite a lot of recent pages.

According to that page they used the Chrome User Experience Report, which is a dataset of sites used by Chrome users, which they did crawl recently. See: https://almanac.httparchive.org/en/2020/methodology#websites

Although I agree that this dataset may weigh towards newer-ish sites, I feel my point still stands.

An other bias though is private apps. React and other frameworks being used for apps more than just websites, these contents aren't always accessible to crawlers, which makes real-world stats difficult to get.

I did consider this, but felt I already proved my point. I completely agree with this based on personal experience. For my work I do use frameworks, but those applications are rarely exposed to the public.

@aberba
Copy link
aberba commented Jan 18, 2021

How many of those results were from Africa? Very few. Same applies to other regions like especially Asia. The sample size was too small and unevenly distributed.

My point is react might seem very popular depending on the reality you live in and the people you follow on Twitter, etc.

@WellRedPandit
Copy link

purely FYI: https://azangru.livejournal.com/1365942.html
just passing it on to you... don't shoot the messenger :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment