Closed Miamoto-Musashi closed 3 years ago
@Miamoto-Musashi Hi.
I would not say that it's a bug. In this case JSON
key pages
for list object used for value name for type names as List<Pages>
and for unnamed list object inside the pages list Pages
. It possible to remove s
letter but I don't know if not defect names and I'm not sure if all plural words have s
at the end? Need to test.
yes Is in the middle from a bug and an enhancement, let's say the expected behavior is to have List
Probably introducing references between objects (see task #45 ) can solve both
Best
@Miamoto-Musashi I have consulted with a friend who speaks English. And he said that it would work 99% to remove only s
at the end for the rest 1% he not garante 😁 From which word to delete s
, the list value will say that word are the plural.
I will fix it as soon as possible.
Just would like to add that there's some cases where trimming s
isn't enough. Imagine countries
for example, it should be changed to country
, but then there might be i18n issues because I'm not sure if replacing ies
by y
always solves the problem.
Just would like to add that there's some cases where trimming
s
isn't enough. Imaginecountries
for example, it should be changed tocountry
, but then there might be i18n issues because I'm not sure if replacingies
byy
always solves the problem.
@Ascenio Thanks for the correction. You are right.
Describe the bug models from array struct are generated in plural forms
To Reproduce given the json
and using json generation the model generated is
Expected behavior Class name should be
Page
Screenshots If applicable, add screenshots to help explain your problem.
Version 3.2.5
Json see above
Additional context using Jsonc file generation