add-typescript-to-cypress icon indicating copy to clipboard operation
add-typescript-to-cypress copied to clipboard

Add support for Yarn PnP

Open nodeworks opened this issue 6 years ago • 2 comments

Thank you for taking time to open a new issue. Please answer a few questions to help us fix it faster. You can delete text that is irrelevant to the issue.

Is this a bug report or a feature request?

Feature request

If this is a bug report, please provide as much info as possible

  • version
  • platform
  • expected behavior
  • actual behavior

If this is a new feature request, please describe it below

Add support for Yarn PnP. Currently it breaks because the post-install script uses a relative directory to check for the cypress folder:

const root = path.join(process.cwd(), '..', '..', '..')

With Yarn PnP it does not use the node_modules folder. The folder it installs in is a path like this:

.yarn/unplugged/@bahmutov-add-typescript-to-cypress-virtual-782a3ce2bf/node_modules/@bahmutov/add-typescript-to-cypress/src/add-plugin.js

nodeworks avatar Oct 23 '19 18:10 nodeworks

Got the same issue? Was it fixed?

error C:\Users\*\node_modules\@bahmutov\add-typescript-to-cypress: Command failed. Exit code: 1 Command: node src/add-plugin.js Arguments: Directory: C:\Users\*\node_modules\@bahmutov\add-typescript-to-cypress Output: ⚠️ Cannot find "cypress" folder in C:\Users\*

We have monorepo and there is no way to install it now :s

pardonmeme avatar Jan 30 '20 12:01 pardonmeme

Seems to be related to https://github.com/cypress-io/cypress/issues/8008

RiZKiT avatar Aug 04 '20 15:08 RiZKiT