Skip to content
New issue

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

JsonSchemaGeneratorSettings made into abstract #1668

Open
kotpal opened this issue Jan 17, 2024 · 1 comment
Open

JsonSchemaGeneratorSettings made into abstract #1668

kotpal opened this issue Jan 17, 2024 · 1 comment

Comments

@kotpal
Copy link

kotpal commented Jan 17, 2024

With the latest (11.0.0) NJsonSchema, JsonSchemaGeneratorSettings seems to be made into an abstract class - which is breaking any code that is creating an instance of it.

It looks like NJsonSchema.NewtonsoftJson package needs to be installed and instead of JsonSchemaGeneratorSettings
NewtonsoftJsonSchemaGeneratorSettings needs to be used.

This should be better documented.

@simeyla
Copy link

simeyla commented Feb 13, 2024

Also NewtonsoftJsonSchemaGeneratorSettings needs to be better documented (I couldn't find it mentioned anywhere).

I'm sure I'm not the only one who updated to v14 and had a nightmarish time trying to get my Angular entities to match what I used to have now that System.Text drives the default generator. And that's because I have a lot of existing code, and the two libraries behave differently and use different attributes. It was an unnecessary source of frustration.

I had to switch to NewtonsoftJsonSchemaGeneratorSettings to preserve my sanity(!), but I had to figure that out myself from looking through the code.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants