google / google/json_serializable.dart

Serialize/deserialize positional records as lists

Open
#1,321 10 comments 3 reactions 0 assignees View on GitHub
Type: enhancement
Dominant language
Dart
Stars
1.6k
Forks
461
Avg merge
45m
Merged PRs (30d)
1

Description

Appreciate the quick work on getting records implemented for `json_serializable`.

One request that I have is for records that _only_ contain positional fields be serialized/deserialized as lists so that if I have this JSON list of `double`s:

```json
[0.34, 0.123, 0.542, 0.4143]
```

it would be deserialized into:

```dart
(0.34, 0.123, 0.542, 0.4143)
```

and vice versa.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.