`@jsxRuntime` pragma
The TSConfig reference claims that adding a
/* @jsxRuntime automatic */
comment to a file has the same effect as setting compilerOptions.jsx
to "react-jsx"
for that file, but this doesn't seem to be the case. I have a main.tsx
file with the following content.
Without a config file, deno check main.tsx
reports an error: “JSX element type '<>' does not have any construct or call signatures”, but if I create a deno.json
file with compilerOptions.jsx
set (which I expected to do nothing because there's already a @jsxRuntime
pragma), the error goes away.
Am I missing something, and is there a way to suppress this error without having to make a config file or adding a ignore comment?0 Replies