Json to Dart Model extension can convert JSON objects into Dart data classes. It supports pure Dart class conversion, Flutter-recommended JSON serialization using annotations, Freezed support, Effective Dart:Style, and many more features. Currently, it has more than 135,000 installs.
Describe the bug I get and error of type
Cannot read property 'type' of undefined
while trying to parse empty lists.To Reproduce Steps to reproduce the behavior:
Expected behavior The extension generates several Dart models.
Screenshots
Version v2.2.0
Json
Additional context The problem its not consistent with empty lists. This specific one happens when there's an empty list and a 2 level nested JSON.