CodeYourFuture / curriculum

The CYF Curriculum
https://curriculum.codeyourfuture.io
Other
28 stars 32 forks source link

[Module-JS2] Consider removing redundant package.json files from sub-folders #829

Open pseudopilot opened 1 month ago

pseudopilot commented 1 month ago

Describe the bug

It's not really a bug but maybe we need to remove few extra package.json files.

In the root of Module-JS2 we have readme.md which says:

To setup this repo, you'll need to install dependencies in the root of this repo. Double check you're in the root of this repo, and then run npm install.

You will only need to run npm install once in the root. After that, the sub-directories should be able to reference the dependencies installed at the root.

In the meantime we have package.json files also provided in the following subfolders:

If the trainees are told to run npm install only once in the root of the repo and in general to work on the module as a whole, does it make sense to remove all package.json files from the nested folders?

I didn't see such a duplication in any other modules.

CC: @illicitonion

illicitonion commented 3 weeks ago

I suspect the reason for this is that if you've only done one of the exercises, running npm test and getting just the test results for the exercise you've done rather than getting a bunch of failures for things you haven't yet attempted is nice. But I agree that having to npm install a bunch of times and ending up with a bunch of node_modules directories isn't ideal.