Skip to content

Optional type property children for <For> and <Show> is typed as required. #2560

@Xzensi

Description

@Xzensi

Describe the bug

Typescript type explicitly defines property children as required when it's not required.

Illegal according to the typescript type:

<For each={props.groups}>
  {group => (

Has to be:

<For
  each={props.groups}
  children={(group: AddressTotalsGroup): JSX.Element => (
Image

and

Image

Your Example Website or App

n/a

Steps to Reproduce the Bug or Issue

.

Expected behavior

Type linter not erroring on valid component property constraints.

Screenshots or Videos

No response

Platform

n/a

Additional context

No response

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