AstonJ

AstonJ

Preact - what do you think about it? ("Fast 3kB alternative to React")

Anyone have any thoughts about Preact?

They’re saying it’s a “Fast 3kB alternative to React with the same modern API”…

A different kind of library

Closer to the DOM

Preact provides the thinnest possible Virtual DOM abstraction on top of the DOM. It builds on stable platform features, registers real event handlers and plays nicely with other libraries.

Preact can be used directly in the browser without any transpilation steps.

Small Size

Most UI frameworks are large enough to be the majority of an app’s JavaScript size. Preact is different: it’s small enough that your code is the largest part of your application.

That means less JavaScript to download, parse and execute - leaving more time for your code, so you can build an experience you define without fighting to keep a framework under control.

Big Performance

Preact is fast, and not just because of its size. It’s one of the fastest Virtual DOM libraries out there, thanks to a simple and predictable diff implementation.

We automatically batch updates and tune Preact to the extreme when it comes to performance. We work closely with browser engineers to get the maximum performance possible out of Preact.

Portable & Embeddable

Preact’s tiny footprint means you can take the powerful Virtual DOM Component paradigm to new places it couldn’t otherwise go.

Use Preact to build parts of an app without complex integration. Embed Preact into a widget and apply the same tools and techniques that you would to build a full app.

Instantly Productive

Lightweight is a lot more fun when you don’t have to sacrifice productivity to get there. Preact gets you productive right away. It even has a few bonus features:

  • props, state and context are passed to render()
  • Use standard HTML attributes like class and for

Ecosystem Compatible

Virtual DOM Components make it easy to share reusable things - everything from buttons to data providers. Preact’s design means you can seamlessly use thousands of Components available in the React ecosystem.

Adding a simple preact/compat alias to your bundler provides a compatibility layer that enables even the most complex React components to be used in your application.

Official site:

Our portal:

Popular Frontend topics Top

PragmaticBookshelf
WebAssembly fulfills the long-awaited promise of web technologies: fast code, type-safe at compile time, execution in the browser, on emb...
New
malloryerik
Any thoughts on Svelte? Svelte is a radical new approach to building user interfaces. Whereas traditional frameworks like React and Vue...
New
New
First poster: bot
React is Dead. Long live Reactive Rails! Long live StimulusReflex and ViewComponent!. Let me tell you about the feeling that I get when ...
New
AstonJ
Yew looks really interesting!! What is Yew? Yew is a modern Rust framework for creating multi-threaded front-end web apps with WebAssem...
New
First poster: bot
Tailwind CSS Tools For Developers. A collection of tools designed for developers, to save you and your team time when building websites w...
New
First poster: bot
Dream is an easy-to-use, boilerplate-free Web framework, whose entire API fits on this page! It supports TLS, WebSockets, and GraphQL. H...
New
First poster: bot
Fable 3.1.16 has been released. Link: Release 3.1.16 · fable-compiler/Fable · GitHub
New
First poster: bot
Fable 3.2.3 has been released. Link: Release 3.2.3 · fable-compiler/Fable · GitHub
New
New

Other popular topics Top

axelson
I’ve been really enjoying obsidian.md: It is very snappy (even though it is based on Electron). I love that it is all local by defaul...
New
brentjanderson
Bought the Moonlander mechanical keyboard. Cherry Brown MX switches. Arms and wrists have been hurting enough that it’s time I did someth...
New
foxtrottwist
Here’s our thread for the Keyboardio Atreus. It is a mechanical keyboard based on and a slight update of the original Atreus (Keyboardio ...
New
AstonJ
Just done a fresh install of macOS Big Sur and on installing Erlang I am getting: asdf install erlang 23.1.2 Configure failed. checking ...
New
AstonJ
This looks like a stunning keycap set :orange_heart: A LEGENDARY KEYBOARD LIVES ON When you bought an Apple Macintosh computer in the e...
New
AstonJ
Do the test and post your score :nerd_face: :keyboard: If possible, please add info such as the keyboard you’re using, the layout (Qw...
New
dimitarvp
Small essay with thoughts on macOS vs. Linux: I know @Exadra37 is just waiting around the corner to scream at me “I TOLD YOU SO!!!” but I...
New
DevotionGeo
The V Programming Language Simple language for building maintainable programs V is already mentioned couple of times in the forum, but I...
New
wmnnd
Here’s the story how one of the world’s first production deployments of LiveView came to be - and how trying to improve it almost caused ...
New
Help
I am trying to crate a game for the Nintendo switch, I wanted to use Java as I am comfortable with that programming language. Can you use...
New