clearnotification 0.0.1 copy "clearnotification: ^0.0.1" to clipboard
clearnotification: ^0.0.1 copied to clipboard

This plugin clears all the notification of the app from notifcation tray.

example/lib/main.dart

import 'package:flutter/material.dart';
import 'dart:async';

import 'package:flutter/services.dart';
import 'package:clearnotification/clearnotification.dart';

void main() => runApp(MyApp());

class MyApp extends StatefulWidget {
  @override
  _MyAppState createState() => _MyAppState();
}

class _MyAppState extends State<MyApp> {

  @override
  void initState() {
    super.initState();
  }

  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      home: Scaffold(
        appBar: AppBar(
          title: const Text('ClearNotification-All'),
        ),
        body: Center(
            child: Center(
              child: MaterialButton(
                onPressed: () async {
                  try {
                    await ClearNotification.all;
                  } on PlatformException {
                  }
                },
                child: Text('ClearNotification-All'),
                color: Colors.red,
              ),
            )),
      ),
    );
  }
}
1
likes
20
pub points
0%
popularity

Publisher

unverified uploader

This plugin clears all the notification of the app from notifcation tray.

Homepage

License

unknown (LICENSE)

Dependencies

flutter

More

Packages that depend on clearnotification