Skip to content

With React 19 typings: Cannot find namespace 'JSX'. #1559

@Philipp91

Description

@Philipp91

I previously posted about this here, but I don't want to spam that thread.

node_modules/@dnd-kit/core/dist/components/Accessibility/Accessibility.d.ts:9:129 - error TS2503: Cannot find namespace 'JSX'.

9 export declare function Accessibility({ announcements, container, hiddenTextDescribedById, screenReaderInstructions, }: Props): JSX.Element | null;

We basically need s/JSX.Element/React.JSX.Element to fix this. There are two occurrences in this repo itself, for which I will send a PR. Though this requires updating to v18 typings first.

But most of the JSX.Element occurrences seem to come from the build process, which materializes types that were previously not spelled out explicitly.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions