You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When doing the onboarding for CT, sometimes it claims you are missing a dependency, when you are not. Eg in this example I have both Solid.js and Vite Plugin Solid, but it says I don't:
cypress:scaffold-config:frameworks error when detecting solid-js: Package subpath './package.json' is not defined by "exports" in /Users/lachlanmiller/code/dump/my-solid-app/node_modules/solid-js/package.json
While it is possible to fix, eg like this, we need to have an alternative strategy that does not rely on package.json getting added to the export map for every module on npm.
Desired behavior
Correctly find and determine the module and version.
Test code to reproduce
The easiest way to reproduce would be
yarn create vite my-app --template react
cd into node_modules/react, remove package.json from the exports key in package.json.
Do the Cypress setup and observe it does not detect that you have React installed.
Cypress Version
12
Node version
16
Operating System
Linux, macos
Debug Logs
cypress:scaffold-config:frameworks error when detecting solid-js: Package subpath './package.json' is not defined by "exports"in /Users/lachlanmiller/code/dump/my-solid-app/node_modules/solid-js/package.json
### Other
_No response_
The text was updated successfully, but these errors were encountered:
Current behavior
When doing the onboarding for CT, sometimes it claims you are missing a dependency, when you are not. Eg in this example I have both Solid.js and Vite Plugin Solid, but it says I don't:
Problem is here: https://github.com/cypress-io/cypress/blob/develop/packages/scaffold-config/src/frameworks.ts#L26-L28
Error:
While it is possible to fix, eg like this, we need to have an alternative strategy that does not rely on
package.json
getting added to the export map for every module on npm.Desired behavior
Correctly find and determine the module and version.
Test code to reproduce
The easiest way to reproduce would be
cd
intonode_modules/react
, removepackage.json
from theexports
key inpackage.json
.Do the Cypress setup and observe it does not detect that you have React installed.
Cypress Version
12
Node version
16
Operating System
Linux, macos
Debug Logs
The text was updated successfully, but these errors were encountered: