fluttereffectshimmer

How to get shimmer effect like facebook in flutter?


I am trying to create a video streaming app and want shimmer effect like facebook, any suggestion how to get it?


Solution

  • shimmer 1.0.1 on https://pub.dev/packages/shimmer, a package provides an easy way to add shimmer effect in Flutter project

    enter image description here

    import 'package:shimmer/shimmer.dart';
    
    SizedBox(
      width: 200.0,
      height: 100.0,
      child: Shimmer.fromColors(
        baseColor: Colors.red,
        highlightColor: Colors.yellow,
        child: Text(
          'Shimmer',
          textAlign: TextAlign.center,
          style: TextStyle(
            fontSize: 40.0,
            fontWeight:
            FontWeight.bold,
          ),
        ),
      ),
    );