whatsapp_share
2.0.2, released 3 years ago by an unverified publisher
Share text, links or files to a specific WhatsApp contact from Flutter.
WASM-ready
What it does
This plugin lets you send messages, URLs or local files directly to a chosen WhatsApp contact on Android. It handles the necessary Android file provider configuration and supports Business WhatsApp.
AI-written summary of version 2.0.2, based on the package's README and metadata. Report an inaccuracy
Use it when
- You need to share content to a specific WhatsApp contact from an Android app
- You want a simple API without handling generic share intents
Skip it when
- You target iOS only
- You need cross‑platform sharing
- You prefer a generic share sheet
Strengths
- Simple, single‑method API for messages and files
- Supports Business WhatsApp
- Handles Android file provider setup
Weaknesses
- Android only
- Requires manual AndroidManifest configuration
- No iOS support
Setup
- Kind
- Plugin (native code)
- Effort
- Medium
- Code generation
- No
- Direct dependencies
- 0
Add a FileProvider to AndroidManifest.xml and create res/xml/provider_paths.xml as shown in the README. No build_runner or codegen needed.
```dart
import 'package:whatsapp_share/whatsapp_share.dart';
Future<void> share() async {
await WhatsappShare.share(
text: 'Hello',
linkUrl: 'https://flutter.dev',
phone: '911234567890',
);
}
```Alternatives
Packages that do the same job and could replace whatsapp_share.
- share_plus
Provides generic sharing across platforms, including WhatsApp, without manual provider setup.
92Compare