Skip to content

Commit

Permalink
fix: hard-code JsxElementChildrenPropertyName under react-jsx and rea…
Browse files Browse the repository at this point in the history
…ct-jsxdev
  • Loading branch information
uhyo committed Dec 30, 2024
1 parent d2bac4b commit 35d0c57
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 56 deletions.
4 changes: 4 additions & 0 deletions src/compiler/checker.ts
Original file line number Diff line number Diff line change
Expand Up @@ -33466,6 +33466,10 @@ export function createTypeChecker(host: TypeCheckerHost): TypeChecker {
}

function getJsxElementChildrenPropertyName(jsxNamespace: Symbol): __String | undefined {
if (compilerOptions.jsx === JsxEmit.ReactJSX || compilerOptions.jsx === JsxEmit.ReactJSXDev) {
// In these JsxEmit modes the children property is fixed to 'children'
return "children" as __String;
}
return getNameFromJsxElementAttributesContainer(JsxNames.ElementChildrenAttributeNameContainer, jsxNamespace);
}

Expand Down

This file was deleted.

This file was deleted.

0 comments on commit 35d0c57

Please sign in to comment.