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

Format Dynamically Generated Labels #48

Open
mattwalo32 opened this issue Jan 19, 2021 · 0 comments
Open

Format Dynamically Generated Labels #48

mattwalo32 opened this issue Jan 19, 2021 · 0 comments

Comments

@mattwalo32
Copy link
Collaborator

Currently much of the frontend (especially on the Profile page), is generated from the backend. This leads to the labeling being a bit weird. For example, some enum options are "SOFTWARE_DEVELOPER" instead of "Software Developer" and labels are of the form "firstName" instead of "First Name".

To fix this, we could either:

  1. Make the DB field names/values user friendly
    • This would fix the enum issues, but not the label issue
  2. Format fields based on pattern
    • All DB fields are camel case, and enum fields are all capital, so it would be rather easy to derive a readable version of the fields/enums by doing string replacement
    • This would work well provided proper naming convention is always followed when adding enum options/member fields
  3. Pass labels to the frontend
    • The backend could instruct the frontend how to display all fields
    • This is the most flexible, but it requires a bit of hardcoding on the backend
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

1 participant