this is simple code that show how you can read data from csv file.
some litle data load from csv file and converte it to list data and shows in listview.builder as a simple text.
-
Installing csv package from: https://pub.dev/packages/csv
if you open that link, you can find installation instrument in installation tab. -
Make some csv file and insert them into 'assets/data/' path, like this: your_project/asstes/data/category.csv
note: in my case, the data in category.csv file is in persian language.
- Add csv file path to pubspec.yaml file like this
assets:
- assets/images/
- assets/data/
and then dont forget to geting package
- Based on this repository write your own code and enjoy :))
thanks