[PR #1995] [MERGED] Refactoring Lenses Using Vue Composables #3599

Closed
opened 2026-03-17 01:11:56 +03:00 by kerem · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/hoppscotch/hoppscotch/pull/1995
Author: @RishabhAgarwal-2001
Created: 12/5/2021
Status: Merged
Merged: 1/17/2022
Merged by: @liyasthomas

Base: mainHead: main


📝 Commits (10+)

📊 Changes

10 files changed (+187 additions, -208 deletions)

View changed files

📝 packages/hoppscotch-app/components/http/ResponseMeta.vue (+2 -1)
📝 packages/hoppscotch-app/components/lenses/renderers/HTMLLensRenderer.vue (+17 -70)
📝 packages/hoppscotch-app/components/lenses/renderers/JSONLensRenderer.vue (+10 -44)
📝 packages/hoppscotch-app/components/lenses/renderers/RawLensRenderer.vue (+12 -46)
📝 packages/hoppscotch-app/components/lenses/renderers/XMLLensRenderer.vue (+12 -46)
packages/hoppscotch-app/helpers/lenses/composables/useCopyResponse.ts (+24 -0)
packages/hoppscotch-app/helpers/lenses/composables/useDownloadResponse.ts (+39 -0)
packages/hoppscotch-app/helpers/lenses/composables/usePreview.ts (+39 -0)
packages/hoppscotch-app/helpers/lenses/composables/useResponseBody.ts (+25 -0)
📝 packages/hoppscotch-app/helpers/lenses/lenses.ts (+7 -1)

📄 Description

Work introduced in this PR

  • Created composables and added them to the various lenses, reducing code duplication.

🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/hoppscotch/hoppscotch/pull/1995 **Author:** [@RishabhAgarwal-2001](https://github.com/RishabhAgarwal-2001) **Created:** 12/5/2021 **Status:** ✅ Merged **Merged:** 1/17/2022 **Merged by:** [@liyasthomas](https://github.com/liyasthomas) **Base:** `main` ← **Head:** `main` --- ### 📝 Commits (10+) - [`2e8ff3b`](https://github.com/hoppscotch/hoppscotch/commit/2e8ff3b00ac7fb4095bfe0fad28f7eb1182e3fc2) refactor: improve ui consistency - [`9a50d3a`](https://github.com/hoppscotch/hoppscotch/commit/9a50d3a9d7fe93406a69bbedf136b70c558e8e61) refactor(lenses): composable for html lens - [`2dae549`](https://github.com/hoppscotch/hoppscotch/commit/2dae5491ae6e06e3f85244b716d71838ed5917bd) refactor(lenses): updates to composables - [`d19cb46`](https://github.com/hoppscotch/hoppscotch/commit/d19cb461dbb65d0b8e75873b8e670ced77f1f8d6) refactor(lenses): started json lens - [`a1cfb46`](https://github.com/hoppscotch/hoppscotch/commit/a1cfb4665d45700d181e5b07fd6b2931e3de2b6b) refactor(lenses): started raw lens - [`4a15f34`](https://github.com/hoppscotch/hoppscotch/commit/4a15f34b43eddd7216b342d551665dc503defa69) refactor(lenses): started xml lens - [`6d71b21`](https://github.com/hoppscotch/hoppscotch/commit/6d71b21cfe630dd0038708ffa415287f7f942aca) refactor(lenses): completed - [`2f2a355`](https://github.com/hoppscotch/hoppscotch/commit/2f2a355cacd042d209fdc1e8320f29a96080e8da) Merge branch 'main' into main - [`27d31fe`](https://github.com/hoppscotch/hoppscotch/commit/27d31fe7705274b2a06d5af907b028e049fe8d53) refactor(lenses): comments address - [`500f41d`](https://github.com/hoppscotch/hoppscotch/commit/500f41d4f99c8a7ef996522a097e024f65fbac5b) Merge branch 'main' of https://github.com/RishabhAgarwal-2001/hoppscotch into main ### 📊 Changes **10 files changed** (+187 additions, -208 deletions) <details> <summary>View changed files</summary> 📝 `packages/hoppscotch-app/components/http/ResponseMeta.vue` (+2 -1) 📝 `packages/hoppscotch-app/components/lenses/renderers/HTMLLensRenderer.vue` (+17 -70) 📝 `packages/hoppscotch-app/components/lenses/renderers/JSONLensRenderer.vue` (+10 -44) 📝 `packages/hoppscotch-app/components/lenses/renderers/RawLensRenderer.vue` (+12 -46) 📝 `packages/hoppscotch-app/components/lenses/renderers/XMLLensRenderer.vue` (+12 -46) ➕ `packages/hoppscotch-app/helpers/lenses/composables/useCopyResponse.ts` (+24 -0) ➕ `packages/hoppscotch-app/helpers/lenses/composables/useDownloadResponse.ts` (+39 -0) ➕ `packages/hoppscotch-app/helpers/lenses/composables/usePreview.ts` (+39 -0) ➕ `packages/hoppscotch-app/helpers/lenses/composables/useResponseBody.ts` (+25 -0) 📝 `packages/hoppscotch-app/helpers/lenses/lenses.ts` (+7 -1) </details> ### 📄 Description ## Work introduced in this PR * Created composables and added them to the various lenses, reducing code duplication. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
kerem 2026-03-17 01:11:56 +03:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/hoppscotch#3599
No description provided.