cf-ui vs Preact: What are the differences?
cf-ui: A set of over 50 packages used to build UIs at CloudFlare using projects such as React, Redux, npm, Lerna, and more. While moving to React, we’ve taken our existing Backbone UI framework and rebuilt it from scratch on top of React. This includes over 50 packages that include dozens of components, utilities, test helpers, and more; Preact: A fast 3k React alternative. Preact is an attempt to recreate the core value proposition of React (or similar libraries like Mithril) using as little code as possible, with first-class support for ES2015. Currently the library is around 3kb (minified & gzipped).
cf-ui and Preact are both open source tools. It seems that Preact with 23.1K GitHub stars and 1.2K forks on GitHub has more adoption than cf-ui with 1.29K GitHub stars and 89 GitHub forks.
What is cf-ui?
What is Preact?
Need advice about which tool to choose?Ask the StackShare community!
Why do developers choose cf-ui?
Sign up to add, upvote and see more prosMake informed product decisions
What are the cons of using cf-ui?
What are the cons of using Preact?
Sign up to get full access to all the companiesMake informed product decisions
What tools integrate with cf-ui?
Sign up to get full access to all the tool integrationsMake informed product decisions
Simple controls over complex technologies, as we put it, wouldn't be possible without neat UIs for our user areas including start page, dashboard, settings, and docs.
Initially, there was Django. Back in 2011, considering our Python-centric approach, that was the best choice. Later, we realized we needed to iterate on our website more quickly. And this led us to detaching Django from our front end. That was when we decided to build an SPA.
For building user interfaces, we're currently using React as it provided the fastest rendering back when we were building our toolkit. It’s worth mentioning Uploadcare is not a front-end-focused SPA: we aren’t running at high levels of complexity. If it were, we’d go with Ember.js.
However, there's a chance we will shift to the faster Preact, with its motto of using as little code as possible, and because it makes more use of browser APIs. One of our future tasks for our front end is to configure our Webpack bundler to split up the code for different site sections. For styles, we use PostCSS along with its plugins such as cssnano which minifies all the code.
All that allows us to provide a great user experience and quickly implement changes where they are needed with as little code as possible.
The first and most important premise is that should be fast.. really fast. This premise was basically because this is an PWA project, and the main goal of this project are be more efficient on restaurant.
So I ended up choosing Preact instead React .
This made the app (PWA) more faster, not only when navigating but improve TTI and data usage.