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

Router Organization #159

Closed
Goose-Of-War opened this issue Jun 12, 2023 · 2 comments · Fixed by #179
Closed

Router Organization #159

Goose-Of-War opened this issue Jun 12, 2023 · 2 comments · Fixed by #179
Assignees
Labels
enhancement Improvements to an existing feature

Comments

@Goose-Of-War
Copy link
Member

Here's what the beginning of our route.js file looks like right now:

const checkerRouter = require("../routes/checker");
const corsProxyRouter = require("../routes/corsProxy");
const govPortalRouter = require("../routes/govportal");
const gitHookRouter = require("../routes/git-hook");
const homeRouter = require("../routes/home");
const liveRouter = require("../routes/live");
const mediaRouter = require("../routes/media");
const membersRouter = require("../routes/members");
const miscRouter = require("../routes/misc");
const newsletterRouter = require("../routes/newsletter");
const pollRouter = require("../routes/polls");
const profileRouter = require("../routes/profile");
const quizzesRouter = require("../routes/quizzes");
const userRouter = require("../routes/user");
const eventsRouter = require("../routes/py-events");

As you can imagine... that's a lot of stuff. And when we proceed with more branched routes (for instance /gov-portal/poll/add-poll, the number of routers will just increase...

We need a better way of organizing this. I have an idea which I am open to share

@PartMan7
Copy link
Member

fs.readdir Y/Y

@Goose-Of-War
Copy link
Member Author

(spoiler alert ;-;)

@Goose-Of-War Goose-Of-War added the enhancement Improvements to an existing feature label Jun 12, 2023
@Goose-Of-War Goose-Of-War self-assigned this Jun 18, 2023
@Goose-Of-War Goose-Of-War linked a pull request Jun 18, 2023 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement Improvements to an existing feature
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants