flutter_mailer 0.0.4 copy "flutter_mailer: ^0.0.4" to clipboard
flutter_mailer: ^0.0.4 copied to clipboard

outdated

Share an email to device Email - Client supports multiple Attachments

flutter_mailer #

pub package

Share an email to device Email Client - supports multiple Attachments

based off of react-native-mail

  • ✅ android
  • ✅ ios - work in progress.
    final MailOptions mailOptions = MailOptions(
      body: 'a long body for the email <br> with a subset of HTML',
      subject: 'the Email Subject',
      recipients: ['example@example.com'],
      isHTML: true,
      bccRecipients: ['other@example.com'],
      ccRecipients: ['third@example.com'],
      attachments: [ 'path/to/image.png', ],
    );

    await FlutterMailer.send(mailOptions);

note gmail and other apps Might parse HTML out of the body.

Getting Started #

Android setup #

this plugin uses FileProvider for android if you are using a conflicting plugin such as image_picker you'll need to edit your applications AndroidManifest.xml file with the following.

<manifest xmlns:android="http://schemas.android.com/apk/res/android"
  package="com.company.appId"
  xmlns:tools="http://schemas.android.com/tools" <!--  add this --> 
  >
  ....
  <application 
  ....
  >
  <!-- vv   add this   vv  -->
  <provider 
    tools:replace="android:authorities"
    android:authorities="${applicationId}.adv_provider"
    android:name="android.support.v4.content.FileProvider" >
    <meta-data
        tools:replace="android:resource"
        android:name="android.support.FILE_PROVIDER_PATHS"
        android:resource="@xml/flutter_mailer_paths"
        />
  </provider>
  ...

For help getting started with Flutter, view our online documentation.

For help on editing plugin code, view the documentation.

80
likes
0
pub points
96%
popularity

Publisher

unverified uploader

Share an email to device Email - Client supports multiple Attachments

Repository (GitHub)
View/report issues

License

unknown (license)

Dependencies

flutter

More

Packages that depend on flutter_mailer