Ts-jest: pnpnm workspaces and project root

Created on 28 Jan 2019  路  3Comments  路  Source: kulshekhar/ts-jest

I get a ts-jest[config] (WARN) Unable to find the root of the project where ts-jest has been installed. warning when using in a pnpm workspace.
It doesn't seem to be impacting the transpilation or type checking though.
Is there any way I can fix this?

Most helpful comment

I have the same issue using ts-jest with ppm. Looks like it may be related to https://github.com/kulshekhar/ts-jest/issues/823.

All 3 comments

Hi. This is not enough information for us to do anything with. Please open a new issue, and follow the issue template. Thanks!

I have the same issue using ts-jest with ppm. Looks like it may be related to https://github.com/kulshekhar/ts-jest/issues/823.

The workaround is to explicit specify the package.json.

jest.config.js:

module.exports = {
  preset: "ts-jest",
  testEnvironment: "node",
  globals: {
    "ts-jest": {
      packageJson: "package.json",
    },
  },
}

Can we make ts-jest config:init include that global setting by default?

Was this page helpful?
0 / 5 - 0 ratings

Related issues

golddranks picture golddranks  路  3Comments

remcohaszing picture remcohaszing  路  4Comments

Slessi picture Slessi  路  3Comments

bruk1977 picture bruk1977  路  3Comments

RiJung picture RiJung  路  4Comments