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

Directory structure #57

Open
eliasmalik opened this issue Mar 20, 2016 · 1 comment
Open

Directory structure #57

eliasmalik opened this issue Mar 20, 2016 · 1 comment

Comments

@eliasmalik
Copy link
Collaborator

I think the current structure is problematic for a few reasons:

  • Project configuration files are split over three directories instead of all living in the project root
  • Two package.json files suggests two different projects with two different sets of dependencies, but this is one project. It will be deployed as a whole.
  • Packages are duplicated between the two different node_modules; no reason for not sharing common modules. (cd into the root and run diff frontend/node_modules backend/node_modules | grep identical or diff frontend/node_modules backend/node_modules | grep Common to see the list of duplicate files — there’s quite a few.
  • After pulling you have to run npm i twice in different directories
  • Scripting is made awkward by having to litter cd ../*end or similar throughout (c.f. pre-commit hook or post install script, or to run all tests, I have to do cd frontend && npm test && cd ../backend && npm test)

At the very least, I think we should extract the config files, package.json(s) and test directories to the root level. You can still run tests for backend and front-end separately by using command-line arguments in the runner.js (see process.argv).

What do you think?

@katbow
Copy link
Collaborator

katbow commented Mar 23, 2016

Agreed with this, MIGHT be something we can look into during code review tomorrow. We'll see what other issues pop up over that

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