README
This commit is contained in:
parent
e3ccf98b69
commit
328224fc10
1 changed files with 2 additions and 0 deletions
|
@ -161,6 +161,7 @@ tend to be snake_cased. This is not a problem, because we can define an alias
|
|||
for a field.
|
||||
|
||||
```dart
|
||||
@serializable
|
||||
abstract class _Spy extends Model {
|
||||
/// Will show up as 'agency_id' in serialized JSON.
|
||||
///
|
||||
|
@ -178,6 +179,7 @@ In pratice, there may keys that you want to exclude from JSON.
|
|||
To accomplish this, simply annotate them with `@exclude`:
|
||||
|
||||
```dart
|
||||
@serializable
|
||||
abstract class _Whisper extends Model {
|
||||
/// Will never be serialized to JSON
|
||||
@exclude
|
||||
|
|
Loading…
Reference in a new issue