File tree Expand file tree Collapse file tree 1 file changed +27
-0
lines changed
Expand file tree Collapse file tree 1 file changed +27
-0
lines changed Original file line number Diff line number Diff line change @@ -52,6 +52,33 @@ const models = await generator.generateCompleteModels(schema, {
5252
5353The generated Python code behavior remains unchanged - all imports will continue to use the explicit style.
5454
55+ ## Typescript
56+ ### Date formats now generate ` Date ` instead of ` string `
57+
58+ In Modelina v5, OpenAPI schema fields with type ` string ` and formats such as
59+ ` date-time ` , ` date ` , or ` time ` were generated as ` string ` in TypeScript models.
60+
61+ Starting from v6, these formats are now mapped to the native ` Date ` type.
62+
63+ This is a ** breaking change** and may require updates in consumer code.
64+
65+ #### What changed
66+
67+ ** Before (v5):**
68+ ``` ts
69+ sentAt ?: string ;
70+ ```
71+
72+ ** After(v6):**
73+ ``` ts
74+ sentAt ?: Date ;
75+ ```
76+ #### Migration notes
77+
78+ - Update TypeScript type annotations that previously expected ` string `
79+ - Ensure any custom serialization or parsing logic handles ` Date ` objects
80+ - Update mocks, tests, and fixtures that rely on string values for date fields
81+
5582## AsyncAPI
5683
5784### Improved schema naming strategy
You can’t perform that action at this time.
0 commit comments