Skip to content

Commit f8a06f6

Browse files
committed
Update v10_00.md
1 parent 3e9b9c3 commit f8a06f6

File tree

1 file changed

+18
-0
lines changed

1 file changed

+18
-0
lines changed

MyApp/_pages/releases/v10_00.md

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -572,6 +572,24 @@ export class CreateBooking implements IReturn<IdResponse>, ICreateDb<Booking>
572572
}
573573
```
574574

575+
### Override Nullable Annotations
576+
577+
Languages with nullable annotations like TypeScript will allow you to control optional properties for each property with `IsPropertyOptional`, e.g:
578+
579+
```csharp
580+
TypeScriptGenerator.IsPropertyOptional = (ts, type, prop) =>
581+
{
582+
// Custom Impl
583+
if (ShouldBeOptional(type, prop))
584+
return true;
585+
if (ShouldBeRequired(type, prop))
586+
return false;
587+
588+
// Default Impl
589+
return TypeScriptGenerator.DefaultIsPropertyOptional(ts, type, prop);
590+
};
591+
```
592+
575593
## SVG Creator
576594

577595
To reduce the artifacts in our starting project templates we're replacing SVGs for pre-configured users to use inline data URIs which is now generated using the new `SvgCreator` class which lets you create random SVG images from the first letter of a users name and a random background color:

0 commit comments

Comments
 (0)