Connect blob page to Vue Router and use it to generate axios request url

Everyone can contribute. Help move this issue forward while earning points, leveling up and collecting rewards.

  • Close this issue

When uploading a blob modal, the request path is generated from Vue router.

https://gitlab.com/gitlab-org/gitlab/blob/9860379415fbf3d168eede7e8bcceabae4934ede/app/assets/javascripts/repository/components/upload_blob_modal.vue#L194

const {
  $route: {
    params: { path },
  },
} = this;

const uploadPath = joinPaths(this.path, path);
return this.submitRequest('post', uploadPath);

In this MR > !62880 (merged), we added support for "replacing a blob". The request path is based on the prop replacePath that is coming from HAML's data attribute. Let's instead make it consistent with the behaviour of "uploading" and switch it to use Vue router.

  1. Connect Vue router to blob show page > app/assets/javascripts/pages/projects/blob/show/index.js
  2. Remove `replacePath
  3. Create the axio request url from the path information of Vue router.
Edited Sep 22, 2025 by 🤖 GitLab Bot 🤖
Assignee Loading
Time tracking Loading