Closed XanderD99 closed 4 months ago
create openapi spec with a path like
/nearby: get: summary: Get nearby places tags: - Generic - Locations responses: '200': description: Return everything nearby content: application/json: schema: type: object properties: locations: type: array items: $ref: '#/components/schemas/Location'
run swagger parsert
typed reponse schema for the response with properties
@Freezed() class GetNearbyResponse with _$GetNearbyResponse { const factory GetNearbyResponse({ required List<Locations> locations, }) = _GetNearbyResponse; factory GetNearbyResponse.fromJson(Map<String, Object?> json) => _$GetNearbyResponseFromJson(json); }
response class with no child parameteres
@Freezed() class GetNearbyResponse with _$GetNearbyResponse { const factory GetNearbyResponse() = _GetNearbyResponse; factory GetNearbyResponse.fromJson(Map<String, Object?> json) => _$GetNearbyResponseFromJson(json); }
/nearby: get: summary: Get nearby places tags:
No response
@XanderD99 Hi, this should be fixed in the latest version, can you test it with your examples?
Steps to reproduce
create openapi spec with a path like
run swagger parsert
Expected results
typed reponse schema for the response with properties
Actual results
response class with no child parameteres
Your OpenApi snippet
/nearby: get: summary: Get nearby places tags:
Code sample
No response
Logs
No response
Dart version and used packages versions
Dart version
```console Dart SDK version: 3.3.3 (stable) (Tue Mar 26 14:21:33 2024 +0000) on "macos_arm64"```Packages version
```console ^1.17.2 ```