Refactor commit list to a Vue Component
The "author dropdown" is a Vue component and the "commits list" is written in vanilla javascript. In order for the former to interact with the latter, we're mixing two different ingredients that are not recommended in our style guide. We might want to consider refactoring the "commit list" to a Vue component.
But here are some other considerations to factor in:
- If we refactor the commit list, then we might also need to update "Filter by commit message" and "branch dropdown" because these also interact with the commit list.
- This might end up being a big investment, so before we dive in, we should weigh if we plan on adding more features to it to justify the resource and time dedicated to this refactor. If not, maybe we should stick with the against the style guide solution
😖
The following discussion from !28509 (merged) should be addressed:
-
@jivanvl started a discussion: (+2 comments) Note While I understand that the existing commit list is not a vue component, I'd like the maintainer to take a look at this one, looks good to me but considering our stance about mixing non Vue code with vanilla and/or jQuery, I'd prefer if we can get a second opinion on this one
https://docs.gitlab.com/ee/development/fe_guide/vue.html#mixing-vue-and-jquery
Thanks for flagging this! Ya, I'm not a fan of that too
😖 I'm not sure what other way around it since the others aren't Vue components. I know it's not ideal, but I think we continue to work iteratively from here still. I think the next step would to follow up with some tickets to convert the rest of the components on the page to a Vue app. That way, we don't have 2 different mix colliding with each other.