jsx, is not a public API react/jsx-runtime からimport して使えるやーーん import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime"; const Foo = () => { return _jsxs( "div", { children: [ _jsx("p", { id: "a", children: "I am foo" }, void 0), _jsx("p", { children: "I am foo2" }, "b"), ], }, void 0, ); }; 16
jsx, is not a public API jsx のコメントを見た感じは、使えないではなく使ってもこっちは知らないよみたいな ニュアンスなのかなと感じています。 /** * Create a React element. * * You should not use this function directly. Use JSX and a transpiler instead. */ export function jsx( type: React.ElementType, props: unknown, key?: React.Key, ): React.ReactElement; 17