Let’s create a new Laravel project using composer by entering the following command to the command line interface.
composer create-project — prefer-dist laravel/laravel laravel-react
Change the current working directory to our new Laravel project.
Let’s set the preset to React.
php artisan preset react
Finally, let’s install the dependencies for React.
That’s how simple it is to use React in a Laravel Project.