Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Better code structure #166

Copy link
Copy link
Open
Open
Copy link
@wildan3105

Description

@wildan3105
Issue body actions

Current behavior:
Currently, because the repo is full-stack which means frontend and backend are stored in the same repo, the folder structure is a bit messy. So we need to re-structure the folder & files based on the best practice while still not breaking any functionality. Also, in the future, I prefer to move from template engine to a js frontend framework like react. So we need to make this to be future proof or at least make it easy towards that goal.

Expected behavior:
Proposed solution:

├── public --> only store static files (image, json file, localization)
│   ├── css
│   └── image
│   └── json
│   └── js (this to make it backward compatible for public utils)
├── src --> store "full-stack" files but differentiate it on the child folder
│   ├── index.js -> boot file
│   ├── api -> backend-related files
│   ├── ├── app.js
│   └── ├── controller.js
│   └── ├── routes.js
│   └── ├── service.js
│   ├── pages -> frontend, template engine files
│   └── ├── layouts
│   └── ├── partials
│   └── ├── index.handlebars
│   ├── utils --> store all utilization file
│   ├── ├── emoji_generator.js
│   ├── ├── language_colors_generator.js
├── config --> store all configuration files
│   ├── api_url.js
│   ├── error_messages.js
│   ├── statements.js
├── tests --> store all unit tests
└── .github/
└── .editorconfig
└── .eslintrc.json
└── .gitignore
└── .travis.yml
└── CODE_OF_CONDUCT.md
└── CONTRIBUTING.md
└── gulpfile.js
└── LICENSE
└── package-lock.json
└── package.json
└── README.md
└── screenshot.png

Please help to suggest something 😃

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      Morty Proxy This is a proxified and sanitized view of the page, visit original site.