In this article, we will build a To-do app using Preact with Full Crud Functionality.

What is Preact?

Preact is a Javascript library, although similar to React, but tiny. At the moment of writing, the main Preact library is around 4Kb. This is small enough that it’s possible to add React-like features to web pages in barely more code than is required to write native JavaScript.

Preact is not React. It is a separate library, but it is designed to be as close to React as possible while much smaller. Preact lets you choose how to use it: a small JavaScript library included in a web page (the no tools approach) or as a full-blown JavaScript application.

Why use Preact over React?

React applications can be large. There are times when you might wish to construct an app with React-like attributes, however, without needing to download a massive amount of JavaScript code.

If you want React-features but don’t want to pay the expense of a React-size JavaScript bundle, you might prefer to consider using Preact. However, it does have a downside. React’s virtual DOM requires a lot of code to keep it up to date. It needs to manage an entire synthetic event model, which parallels the one in the browser.


#preact #react #javascript #web-development

Building a CRUD Application using Preact
4.60 GEEK