Skip to content

Computed field marked as optional should generate a nullable type #33

Closed
@Azzerty23

Description

@Azzerty23

Description and expected behavior
A computed field marked as optional should generate a "nullable type", such as OperandExpression<number | null>, instead of OperandExpression<number>.

Environment (please complete the following information):

  • ZenStack version: [e.g., 3.0.0-alpha.4]

Additional context
See agePlus2 computed field in the generated schema.ts and the corresponding typing issue here.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions