typescript icon indicating copy to clipboard operation
typescript copied to clipboard

Solving definitions issues

Open fredericbarthelet opened this issue 5 years ago • 3 comments
trafficstars

Solving issues listed in https://github.com/serverless/typescript/README.md with solution for discontinued maintenance of json-schema-to-typescript -> https://github.com/bcherny/json-schema-to-typescript/issues/347

fredericbarthelet avatar Nov 15 '20 18:11 fredericbarthelet

Switching to quicktype ? -> https://github.com/quicktype/quicktype -> https://dev.to/okeeffed/generating-types-from-json-schema-with-quicktype-1fh2

fredericbarthelet avatar Nov 24 '20 10:11 fredericbarthelet

Issue on custom property not accepting additional properties : https://github.com/quicktype/quicktype/issues/1615

fredericbarthelet avatar Dec 20 '20 12:12 fredericbarthelet

it seems that s3 event definition is not correctly converted

https://github.com/serverless/typescript/blob/master/index.d.ts#L164

should be

            s3:
              | string
              | {
                  bucket: string | AwsCfFunction;
                  event?: string;
                  existing?: boolean;
                  rules?: {
                    suffix?: string;
                  }[] | {
                      prefix?: string;
                  }[];
                };
          }

as AJV schema wants only 1 property Configuration warning at 'functions.lambda_name.events[0].s3.rules[0]': should NOT have more than 1 properties

spawn-guy avatar Jul 21 '21 12:07 spawn-guy