google / google/json_serializable.dart
JsonConverter with import prefix
Open
State: help wanted
Type: enhancement
- Dominant language
- Dart
- Stars
- 1.6k
- Forks
- 461
- Avg merge
- 45m
- Merged PRs (30d)
- 1
Description
I have a `CustomJsonConverter` defined in a separate library which i want to import using a library prefix.
```dart
import 'library.dart' as converter;
@JsonSerializable()
class MyObject {
// ....
@converter.CustomJsonConverter()
final CustomObject value;
}
```
but the generated code uses `CustomJsonConverter.toJson` instead of including the `converter.` library prefix.
Not a big problem, since i could just remove the prefix, but it would be nice if this was supported.
Contributor guide
Assessment
This issue has not been assessed yet.