TsubasaT
Denoβ€’10mo agoβ€’
14 replies
Tsubasa

JSX config not working properly, I keep getting children props error in all my components

Property 'children' is missing in type '{ in: true; timeout: number; }' but required in type 'FadeProps'.deno-ts(2741)

I have similar project with same configs with npm and node and it works fine, but I can't seem to make it work with deno.

Here's my
deno.json
and tsconfig.json (I also tried adding same configs in tsconfig.node.json and tsconfig.app.json also has similar settings)

{
    "compilerOptions": {
        "moduleResolution": "node",
        "baseUrl": ".",
        "paths": {
            "@/*": [
                "./src/*"
            ]
        },
        "jsx": "react-jsx",
        "jsxImportSource": "react",
    },
    "composite": true,
    "include": ["src"],
    "files": [],
    "references": [
        { "path": "./tsconfig.app.json" },
        { "path": "./tsconfig.node.json" }
    ]
}


{
    "imports": {
        "@oak/oak": "jsr:@oak/oak@^17.1.4",
        "@tajpouria/cors": "jsr:@tajpouria/cors@^1.2.1",
        "react": "npm:react"
    },
    "nodeModulesDir": "auto",
    "compilerOptions": {
      "lib": [
        "ES2020",
        "DOM",
        "DOM.Iterable",
        "esnext"
      ],
      "jsx": "react-jsx",
      "jsxImportSource": "react",
      "jsxFactory": "React.createElement",
      "jsxFragmentFactory": "React.Fragment"
    },
    "unstable": [
      "sloppy-imports"
    ],
    "lint": {
        "rules": {
            "include": [
                "ban-ts-comment",
                "no-irregular-whitespace",
                "jsx-no-children-prop"
            ]
        }
    },
    "fmt": {
        "indentWidth": 4,
        "singleQuote": true
    }
}
Was this page helpful?