React-table: Error with v7 and typescript 3.7.3

Created on 6 Dec 2019  路  1Comment  路  Source: tannerlinsley/react-table

Describe the bug
I update typescript from 3.7.2 to 3.7.3, and I got these error.

import { useTable } from "react-table";
         ^^^^^^^^
import useTable
error TS2614: Module '"../../../../../../../${my_dir}/node_modules/@types/react-table"' has no exported member 'useTable'. Did you mean to use 'import useTable from "../../../../../../../${my_dir}/node_modules/@types/react-table"' instead?



md5-ecaedb9ecbcb4e2e85f62d3ed2f6e57b



"dependencies": {
    "axios": "^0.19.0",
    "camelcase-keys": "^6.1.1",
    "node-sass": "^4.13.0",
    "qs": "^6.9.1",
    "react": "^16.11.0",
    "react-app-polyfill": "^1.0.4",
    "react-dom": "^16.11.0",
    "react-helmet": "^5.2.1",
    "react-redux": "^7.1.3",
    "react-router-dom": "^5.1.2",
    "react-scripts": "3.2.0",
    "react-table": "^7.0.0-beta.12",
    "redux": "^4.0.4",
    "redux-saga": "^1.1.3",
    "snakecase-keys": "^3.1.0",
    "ts-optchain.macro": "^1.1.5",
    "typescript": "^3.7.3"
  },
  "devDependencies": {
    "@types/axios": "^0.14.0",
    "@types/axios-mock-adapter": "^1.10.0",
    "@types/classnames": "^2.2.9",
    "@types/jest": "^24.0.22",
    "@types/node-sass": "^4.11.0",
    "@types/prettier": "^1.18.3",
    "@types/qs": "^6.9.0",
    "@types/react": "^16.9.11",
    "@types/react-dom": "^16.9.4",
    "@types/react-helmet": "^5.0.14",
    "@types/react-redux": "^7.1.5",
    "@types/react-router-dom": "^5.1.2",
    "@types/react-table": "^6.8.5",
    "@typescript-eslint/eslint-plugin": "^2.7.0",
    "@typescript-eslint/parser": "^2.7.0",
    "axios-mock-adapter": "^1.17.0",
    "classnames": "^2.2.6",
    "eslint": "^6.6.0",
    "eslint-config-prettier": "^6.5.0",
    "eslint-plugin-react": "^7.16.0",
    "prettier": "^1.19.1",
    "redux-devtools-extension": "^2.13.8"
  }

>All comments

Hmm. React Table v7 doesn't have types in this repo. They are available (or will be soon) over at Definitely Typed though.

More info: https://github.com/tannerlinsley/react-table/blob/master/TYPESCRIPT.md

Was this page helpful?
0 / 5 - 0 ratings

Related issues

esetnik picture esetnik  路  3Comments

dwjft picture dwjft  路  3Comments

panfiva picture panfiva  路  3Comments

krishna-shenll picture krishna-shenll  路  3Comments

danielmariz picture danielmariz  路  3Comments