|
|
|
|
|
by kansface
3799 days ago
|
|
The value proposition of Preact makes no sense to me: > 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. I understand building a faster React, an easier to use React (forms are a nightmare), but a smaller React?
We are talking about saving on the order of 30kb. This doesn't even matter on mobile. Can anyone give me a compelling use case? |
|
Less code can also mean its easier to understand and has pruned the legacy/redundant parts (being ES2015 only).
And being able to read the whole code of your framework in one sitting, and understand it, is great.
Besides, it's not like "as little code as possible" is their ONLY goal. They're not merely building a drop-in React replacement with less code. The reference to "Mithril" looks like they'll also investigate their own APIs and ways of hooking components etc, which will be similar in concept but different than React's exact APIs -- they already dropped the non-stateless components APIs.
[addition] Regarding the "order of 30kb savings". Here's an excerpt from their site: "The React-based demo was 1.8mb of JavaScript. This demo, using exactly the same code and with the same functionality, is 60kb.".