opacity property Null safety

double opacity
final

Opacity of the plot band. The value ranges from 0 to 1.

Defaults to 1.

Widget build(BuildContext context) {
   return Container(
       child: SfCartesianChart(
          primaryXAxis: NumericAxis(
            plotBands: <PlotBand>[
               PlotBand(
                   isVisible:true,
                   opacity: 0.5
               )
             ]
          )
       )
   );
}

Implementation

final double opacity;