From 7665c7e254dc6f1e0b39dd15ca3f5c7d31e74d96 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jose=20Mar=C3=ADa=20G=C3=B3mez?= Date: Thu, 22 Feb 2024 12:04:15 +0100 Subject: [PATCH] Add React version to README.md --- README.md | 70 +++++++++++++++++++++++++++++++++++++++++++++++++++---- 1 file changed, 65 insertions(+), 5 deletions(-) diff --git a/README.md b/README.md index 941df2e..ac8c196 100644 --- a/README.md +++ b/README.md @@ -9,6 +9,7 @@ Check out the [demo app](https://modal.advanced-inertia.com) demonstrating the M - [**Installation**](#installation) - [**Laravel**](#laravel) - [**Vue 3**](#vue-3) + - [**React**](#react) - [**Setup**](#setup) - [**Vite**](#vite) - [**Laravel Mix**](#laravel-mix) @@ -28,8 +29,6 @@ composer require based/momentum-modal ### Vue 3 -> The frontend package is only for Vue 3 now due to its adoption within the Laravel community. - Install the frontend package. ```bash @@ -40,6 +39,24 @@ yarn add momentum-modal > **Warning** > The package utilizes `axios` under the hood. If your app is already using `axios` as a dependency, make sure to lock it to the same version Inertia uses. +> +> ```bash +> npm i axios@1.2.0 +> ``` + +### React + +Install the frontend package. + +```bash +npm i momentum-modal-react +# or +yarn add momentum-modal-react +``` + +> **Warning** +> The package utilizes `axios` under the hood. If your app is already using `axios` as a dependency, make sure to lock it to the same version Inertia uses. +> > ```bash > npm i axios@1.2.0 > ``` @@ -50,6 +67,8 @@ yarn add momentum-modal Put the `Modal` component somewhere within the layout. +### Vue 3 setup + ```vue