Introducing the Rematch library
To introduce the Rematch library in our application, we'll be using the same method that we used previously in Chapter 3, Redux First Steps – Creating a Simple To-Do App, in the Creating our first store section. As we did then, we will be using unpkg.com
. Let's modify the <script />
element under the closing body
tag:
<script src="https://unpkg.com/redux@latest"></script> <script src="https://unpkg.com/@rematch/core@latest"></ script> <script src="./todo-app.js"></script> </body> </html>
Rematch, like Redux, ships in a bundle with ES Modules (ESM), Common JS (CJS), and Universal Module Definition (UMD) builds. You can use Rematch anywhere where you can use Redux.
Rematch is less than 2 kilobytes in size, which means the impact on performance and the most important indicators for measuring that our...