diff --git a/.gitignore b/.gitignore
index 81a80bf..e3dc8b9 100644
--- a/.gitignore
+++ b/.gitignore
@@ -24,4 +24,6 @@ build/
**/example/ios/.symlinks/
**/example/ios/Pods/
+**/example/android/app/.cxx
+
**/ios/Flutter/ephemeral
diff --git a/README.md b/README.md
index 90e80d7..901d39d 100644
--- a/README.md
+++ b/README.md
@@ -1,4 +1,3 @@
-
# reCAPTCHA Enterprise Flutter Module
Please note that issues filed in this repository are not an official Google
@@ -11,9 +10,9 @@ in
[https://github.com/GoogleCloudPlatform/recaptcha-enterprise-mobile-sdk](https://github.com/GoogleCloudPlatform/recaptcha-enterprise-mobile-sdk).
For general documentation on reCAPTCHA Enterprise for mobile applications, see
-[Android](https://cloud.google.com/recaptcha-enterprise/docs/instrument-android-apps)
-and
-[iOS](https://cloud.google.com/recaptcha-enterprise/docs/instrument-ios-apps).
+[Android](https://cloud.google.com/recaptcha-enterprise/docs/instrument-android-apps),
+[iOS](https://cloud.google.com/recaptcha-enterprise/docs/instrument-ios-apps),
+and [Web](https://cloud.google.com/recaptcha-enterprise/docs/instrument-web-apps).
## Integrating reCAPTCHA Enterprise with your Flutter Application
@@ -30,16 +29,25 @@ Flutter application for enhanced security.
flutter pub add recaptcha_enterprise_flutter
```
- **Note:** This library supports only iOS and Android platforms.
+ **Note:** This library supports iOS, Android, and Web platforms.
### 2. Client Initialization
1. **Obtain Site Keys:**
- Acquire your reCAPTCHA Enterprise site keys for both Android and iOS
+ Acquire your reCAPTCHA Enterprise site keys for Android, iOS, and Web
platforms from the Google Cloud Console.
-2. **Instantiate the `RecaptchaClient`:**
+2. **Web Setup:**
+
+ For web, you must include the reCAPTCHA Enterprise script in your
+ `index.html` file. Replace `[MYWEBSITEKEY]` with your actual web site key:
+
+ ```html
+
+ ```
+
+3. **Instantiate the `RecaptchaClient`:**
Initialize the client using the appropriate site key based on the platform.
It's crucial to initialize the client as early as possible within your
@@ -53,9 +61,11 @@ Flutter application for enhanced security.
void main() async {
WidgetsFlutterBinding.ensureInitialized();
- final siteKey = Platform.isAndroid
- ? ""
- : "";
+ final siteKey = kIsWeb
+ ? ""
+ : Platform.isAndroid
+ ? ""
+ : "";
RecaptchaClient client = await Recaptcha.fetchClient(siteKey);
@@ -78,15 +88,12 @@ Flutter application for enhanced security.
```
**Important:**
+ * Replace ``, ``, and `` with your actual reCAPTCHA Enterprise site keys.
+ * For web, make sure the `
+
+
+
+
+