We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Hey Team,
I've encountered an issue in @ovotech/avro-ts@6.2.0 where it doesn't seem to support providing an instance of an Type from the avsc@5.7.7 library
@ovotech/avro-ts@6.2.0
Type
avsc@5.7.7
Here is a minimal reproduction, I would expect the below to work based on the signature of toTypeScript
toTypeScript
const x = toTypeScript( avro.Type.forSchema({ type: 'record', name: 'ExampleEvent', fields: [ { name: 'id', type: 'string' }, { name: 'mobile', type: ['null', 'int'], default: null }, { name: 'name', type: ['null', 'string'], default: null }, ], }), );
I do have a workaround which is just to convert my avro schema to JSON then parse back to a plain ol JS object
const ts = toTypeScript( JSON.parse( JSON.stringify( avro.Type.forSchema({ type: 'record', name: 'ExampleEvent', fields: [ { name: 'id', type: 'string' }, { name: 'mobile', type: ['null', 'int'], default: null }, { name: 'name', type: ['null', 'string'], default: null }, ], }), ), ), );
The text was updated successfully, but these errors were encountered:
No branches or pull requests
Hey Team,
I've encountered an issue in
@ovotech/avro-ts@6.2.0
where it doesn't seem to support providing an instance of anType
from theavsc@5.7.7
libraryHere is a minimal reproduction, I would expect the below to work based on the signature of
toTypeScript
I do have a workaround which is just to convert my avro schema to JSON then parse back to a plain ol JS object
The text was updated successfully, but these errors were encountered: