Santos-Enoque / flutter-web-dashboard-template

270 stars 202 forks source link

bar chart errors can't be assigned to the parameter type 'List<Series<dynamic, String #21

Open hostusservices opened 2 years ago

hostusservices commented 2 years ago

Please help me with the bar chart error

when copy the bar chart code serieslist was showing error says

List<Series<dynamic, dynamic>> seriesList package:flutter_application_1/widgets/bar_chart.dart

Unnecessary new keyword.dartunnecessary_new The argument type 'List<Series<dynamic, dynamic>>' can't be assigned to the parameter type 'List<Series<dynamic, String>>*'

image

please check my code https://github.com/hostusservices/flutter_dashboard.git

Pradeep474832 commented 2 years ago

Change your seriesList variable type from:

final List seriesList;

To:>>>

final List<charts.Series<dynamic, String>> seriesList;