Flutter package for animated switchers in your flutter application
How to Use
To use flutter_animated_switchers, follow the following steps:
Step1: Adding plugin dependency
- add the plugin to your pubspec.yaml file:
flutter_animated_switchers: [latest_version]
Step2: Importing the package.
- import the plugin in
your_file
.dart
import 'package:flutter_animated_switchers/flutter_animated_switchers.dart';
Step3: Call the switcher of your desired Switcher Type
const FlutterAnimatedSwitcher(
switcherType: SwitcherType.styleOne,
),
Step6: Listen to state changes
- you can also listen to state changes from the following two states:
STATE | DESCRIPTION | DATA TYPE / FORMAT |
---|---|---|
State On | When the switcher is turned on | bool: true |
State Off | When the switcher is turned off | bool: false |
FlutterAnimatedSwitcher(
switcherType: SwitcherType.styleFive,
onTap: (() {
print("Tapped");
}),
onStateChanged: ((state) {
print("current state is $state");
}),
)
Example Images:
- Example Gif/Mp4 files for review are as below: (wait while its loading)
Important URL
FAQ
In case you need: to add new feature or you get any error or any help, please contact me at javeriaiffat312@gmail.com or javeria.iffat@lums.edu.pk please be kind if you get any errors, text me I'll be more than happy to help you all.
THANK YOU!