Skip to content
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

Which config could be moved to the parent dir? #18

Closed
danieldietrich opened this issue Feb 25, 2021 · 3 comments
Closed

Which config could be moved to the parent dir? #18

danieldietrich opened this issue Feb 25, 2021 · 3 comments

Comments

@danieldietrich
Copy link
Contributor

  • eslint searches the configuration in the parent dir
  • ./tsconfig.json could extend ../tsconfig.json
  • etc.

This would only make sense if all projects have roughly the same shape, e.g. being node projects.

@spoenemann
Copy link
Contributor

Typescript allows to have a base config that can be extended. That is super useful, so all packages can share settings about compiler checks etc.

Example: https://github.com/eclipse/sprotty/blob/master/tsconfig.json

@danieldietrich
Copy link
Contributor Author

Thx, yes, we already use that in Langium for excluding unit tests from the build (that are considered in the development build). I will move that base config to the root.

@danieldietrich
Copy link
Contributor Author

I've experimented a bit and there seem to emerge more problems that moving config is being helpful.

For example, plugins like typescript-esling/eslint-plugin (for eslint) or jest (for tsconfig) need to be present in the root node_modules folder. Also includes/excludes aren't recognized anymore and need to be overridden in the project-specific configs.

For now I see no benefit in moving (some) configs to the root, so I will close this issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants