Remove obscure propsData usage in provide
What does this MR do and why?
Due to a bug in vue-apollo, we couldn't use props directly this.<propname>
in the provide function of a vue component. Instead we had to take the prop from this.$options.propsData.<propname>
. The fix (which @pslaughter
provided) in vue-apollo was merged a couple days ago and a new release was made containing this fix; vue-apollo: 3.1.1
.
This MR updates vue-apollo and removes the comments and obscure way of accessing the props in the components where I found this behavior.
As part of other fixes in vue-apollo between v3.0.7 and v3.1.1, I've had to update some specs.
How to set up and validate locally
Numbered steps to set up and validate the change are strongly suggested.
Go to following pages and notice there are no console errors regarding the props in provide
(you could add a breakpoint in the provide function to inspect the props):
- For
app/assets/javascripts/super_sidebar/components/sidebar_menu.vue
: http://gdk.test:3000/ - For
app/assets/javascripts/members/components/app.vue
: http://gdk.test:3000/root/gitlab/-/project_members - For
app/assets/javascripts/content_editor/components/content_editor_provider.vue
: Go to any issue and use rich-text-editing - For
ee/app/assets/javascripts/security_dashboard/components/pipeline/pipeline_security_dashboard.vue
:- You need an EE license
- You need to have runners enabled (See $2408961 for setting up a runner)
- Import https://gitlab.com/gitlab-examples/security/security-reports
- Run a pipeline on master
- Go to the pipeline > security tab
- For
app/assets/javascripts/vue_shared/components/vuex_module_provider.vue
: switch to the old navigation (click avatar icon > untoggle New navigation)
MR acceptance checklist
This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.
-
I have evaluated the MR acceptance checklist for this MR.