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

Consistency when naming component #7

Closed
hiendv opened this issue Aug 28, 2017 · 4 comments
Closed

Consistency when naming component #7

hiendv opened this issue Aug 28, 2017 · 4 comments

Comments

@hiendv
Copy link

hiendv commented Aug 28, 2017

You may want to use either dash-separated or PascalCase, not both.

@taquy taquy mentioned this issue Aug 28, 2017
@taquy
Copy link
Owner

taquy commented Aug 28, 2017

Depends on the case I think, these are my preferences (but ofc I will take your advice as consistency naming):

camelCase is chosen for declaring variable and function name.
underscore_separted for sql fields name or api data
dash-separated for template (html) tag or class name.
PascalCase for components name. (as Class name is often chose this form as practice of writing)

@hiendv
Copy link
Author

hiendv commented Aug 28, 2017

@hiendv hiendv reopened this Aug 28, 2017
@taquy taquy added bug and removed enhancement labels Aug 28, 2017
@hiendv
Copy link
Author

hiendv commented Aug 28, 2017

taquy pushed a commit that referenced this issue Aug 28, 2017
@hiendv hiendv closed this as completed Aug 29, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants