Playwright and React.js Typescript Todo App Automated End to End Testing with Vite
Introduction
In this tutorial, we’ll create a simple Todo app using React.js and TypeScript, initialized with Vite, and then we’ll write tests for it using Playwright. We will use playwright to do an end to end test which will simulate the user browser interaction with our todo app like adding new todos, deleting todos, upadtinhg todos e.t.c. By the end of this guide, you’ll have a solid understanding of how to use Playwright to test your React applications.
React.js Typescript Todo App Testing with Jest and React Testing Library and Vite
Introduction
In this tutorial, we shall setup Jest and React Testing Library to perform integration test. We will be testing React.Js components, so this will not be an end to test, but we will be testing the individual coponents involved in the Todo App. At each stage, we will render the components invovled using the library functions provided by React Testing Library. We shall pass in properties to each component and test their behavious and visualisation by simulating clicks and text typing into textboxes using the appropriate functions. Jest will be used as our test runner. These two libraries are independent but work very well together. So let’s get started.
Laravel 11 and React 18 Login and Registration tutorial with React Redux Toolkit
Introduction
In this tutorial, we will be setting up an indepth tutorial guide of react.js and laravel 11 system for user authentication and registration. We will be using typescript on the react.js frontned, along with react redux toolkit, but do not worry as youc an follow along even if you only know javascript. React redux toolkit helps with state management. It might be overkill for a simple login registration app like this, but makes life very easy once the app codebase grows. Users will be able to register using an email as their username and password. After successful registration, they shall be able to login. We wil demonstrate the login mechanism by having a userpforile area/route in the frontend of the application which will be locked and only accessible to logged in. The frontend and backend will be on different domains, so the after logging in, we will provide the user with a token, which will be stored in localstorage of the browser. This will be send along in the header each request which requires authentication to get data back from the server. We will also need to setup cors so that our frontend domain can send requests to the backend domanin app.