-
Notifications
You must be signed in to change notification settings - Fork 208
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
gts monorepo does not work with npm ? #752
Comments
Hi @arvegadev 👋 |
I noticed that gts fix and gts link wasn't working in the npm workspaces. This is related to the issues: gts monorepo does not work with npm ? google/gts#752 gts does not work in a yarn workspaces monorepo google/gts#490 The last issue is with yarn but has more discussion. One solution was using nohoist. This is not a default option with npm. So I tried with the following package https://github.com/zgriesinger/noist. But this did not fix the errors. The last solution mentioned was only linting from the root level; this works. I have also subscribed to the issue [feature] support npm workspaces. There may be a better solution in the future.
With the the latest 5.1.0 release, which includes #654, gts is working pretty well with npm workspaces monorepo for me. You only need the single gts generated .eslintrc.json in your repo root. I did have to move my eslintignore into the .eslintrc.json |
I will try it. Thanks in advance. |
Should be fixed via: |
I have this monorepo structure:
. root ├── node_modules ├── package.json ├── package-lock.json ├── packages │ └── example-package ├── README.md └── release-please-config.json
Then in my root package.json
example-package - package.json
Then I run the lint command:
I don´t underestand why is looking in the concrete example-package instead of the root directory. The only way I found to make it works is copying the node_modules/eslint package into the example-package directory.
/monorepo/packages/example-package/eslintrc.json
Greetings, thanks in advance
The text was updated successfully, but these errors were encountered: