Skip to content

When I install "@testing-library/react": "^11.2.5" in an existing project with tslint, I get missing kcd-scripts warning #883

Closed
@justin-calleja

Description

@justin-calleja
  • @testing-library/react: 11.2.5
  • Testing Framework and version: jest at 26.6.3
  • DOM Environment: jsdom at 11.12.0

What you did:

install "@testing-library/react": "^11.2.5" via adding directly in package.json and lerna bootstrap.

What happened:

Cannot read file '.../node_modules/@testing-library/react/node_modules/kcd-scripts/shared-tsconfig.json'.

Problem description:

A dependency of react-testing-library is not being installed. In react-testing-library's package.json:

 "eslintConfig": {
    "extends": "./node_modules/kcd-scripts/eslint.js",

So my editor now requires the existance of that eslint.js file.

Suggested solution:

Add the missing kcd-scripts in dependencies of react-testing-library.

When I install kcd-scripts alongside @testing-library/react in my package devDependencies (and restart TS server in vs code), then the error goes away. But I would expect that the expected behaviour is to just install @testing-library/react and not get the error in the first place 🙂

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions