-
Notifications
You must be signed in to change notification settings - Fork 20
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
Add PascalCase and remove kebab-case from components #40
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks great! Leaving some quick comments that are nothing you did, but hopefully things you won't mind fixing when you have time? 😅
One thing we could fix here is the component registration. Currently, we're registering components like so:
export default {
components: {
"ChargesPaginationLinks": ChargesPaginationLinks,
},
}
But, since we're using laravel-mix
, which uses webpack/module loading, we can do it more simply.
export default {
components: { ChargesPaginationLinks },
}
resources/js/views/Index.vue
Outdated
export default { | ||
components: { | ||
'balance-card': BalanceCard, | ||
'charges-table': ChargesTable, | ||
'column-select': ColumnSelect, | ||
'BalanceCard': BalanceCard, | ||
'ChargesTable': ChargesTable, | ||
'ColumnSelect': ColumnSelect, | ||
}, | ||
data() { | ||
return { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just a note, since 1) you didn't do it and 2) it'll be cleaned up with the Duster PR (#37), but the baseline indentation inside the <script>
tag should be flush left.
<script>
export default {
components: {
'BalanceCard': BalanceCard,
'ChargesTable': ChargesTable,
'ColumnSelect': ColumnSelect,
},
}
</script>
Okay I made the changes. I also saw that sometimes the components had a trailing comma. I went ahead and went with trailing for all of them. If it would be better to not have it, I can easily take it out. Thanks for reviewing! |
@rissajackson - Yeah, let's remove the commas. They won't cause any problems, but typically we reserve trailing commas for a multi-line statement. |
No description provided.