Skip to content
GitLab
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in / Register
  • O openapi-generator
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 3,476
    • Issues 3,476
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 402
    • Merge requests 402
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Packages and registries
    • Packages and registries
    • Package Registry
    • Infrastructure Registry
  • Monitor
    • Monitor
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • OpenAPI Tools
  • openapi-generator
  • Merge requests
  • !8310

Dart: use JSON-serializable

  • Review changes

  • Download
  • Email patches
  • Plain diff
Closed Administrator requested to merge github/fork/agilob/dart-json-serializable into master Jan 03, 2021
  • Overview 0
  • Commits 1
  • Pipelines 0
  • Changes 77

Created by: agilob

@noordawod @kuhnroyal I attempted to use json_serializable to replace all our manual code. Here's almost finished work, but unfortunately I found a bug in the library

https://github.com/google/json_serializable.dart/issues/784 - google doesn't seem to care too much about handling enums in this library so looks like it won't go any further, unless you have any idea how to fix it manually? Generate _$decode and _$encode on our own?

Here's another attempt to generate enum handling code to produce the same autogenerated code as json_serializer https://github.com/OpenAPITools/openapi-generator/pull/8308 here I hit another bug where complexItem / enum isn't recognised correctly what you can see in second commit

The general direction is to remove our manual work and relay on some library, but I can't find any where enums aren't 3rd class citizens.

Any advice is welcome.

// this is PoC

Assignee
Assign to
Reviewers
Request review from
Time tracking
Source branch: github/fork/agilob/dart-json-serializable