mirror of
https://github.com/ProxymanApp/Proxyman.git
synced 2026-04-26 16:45:57 +03:00
[GH-ISSUE #380] Quick Map Local #379
Labels
No labels
Discussion
Feature request
In Progress...
Plugins
Waiting response
Windows
Windows
bug
duplicate
enhancement
feature
good first issue
iOS
macOS 10.11
question
wontfix
✅ Done
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/Proxyman#379
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @dutzi on GitHub (Jan 22, 2020).
Original GitHub issue: https://github.com/ProxymanApp/Proxyman/issues/380
Originally assigned to: @NghiaTranUIT on GitHub.
Hey,
First I wanted say how nice of a product this is! It's very slick and modern, good job!
I have the following feature suggestion.
My main use case for Proxyman is modifying responses (using Map Local).
The current workflow for this use case is to:
This is a bit cumbersome and for my use case, which I perform regularly, takes longer time than needed.
My idea is:
That way, for said use case, all the user has to do is right click the request, Tools → Quick Map, make the changes within the editor and save the file.
@NghiaTranUIT commented on GitHub (Jan 22, 2020):
Hi @dutzi, thank for the detail feedback.
Your proposal is same what we are working on the Local Map v2 (https://github.com/ProxymanApp/Proxyman/issues/345) and the progress is 70% done.
Basically, you can quick map from current Response (if it's available) or a file and capability to edit directly in Proxyman without jumping to other Editor 😄
The goal is reduce the number steps of doing Local Map 👍
I'm spending the Tet holiday to finalize this feature. Please stay tuned ✊
@dutzi commented on GitHub (Jan 22, 2020):
That's great!
But plz plz plz have an option to open in native editor, there's so many features i use within it for tasks like these :)
@NghiaTranUIT commented on GitHub (Jan 23, 2020):
For sure, v2 Map Local must be super convenience 🙌
@NghiaTranUIT commented on GitHub (Jan 27, 2020):
Hey @dutzi
Let check it out a new release, which including a v2 Map Local 🙌 (https://github.com/ProxymanApp/Proxyman/releases/tag/1.15.0)
From now, we can:
Let check it out 😄
@dutzi commented on GitHub (Jan 27, 2020):
Amazing! Checking it now!
@dutzi commented on GitHub (Jan 27, 2020):
It's sooo much better, I really like it. Thank you.
The only thing I'd change is to comment out the headers within json/js responses.
What I mean is that instead of having a locally mapped .json file look like:
Have it look like:
The reason being is that without the commented out headers the file isn't a legit JSON file (same goes for JS/CSS/etc...). By commenting out the lines we make it compatible with JSON 5 schema IIRC.
The reason for making it confine to the schema is that other tools, like linters or prettiers could still run on the file when using an external editor like VSCode. Prettiers in particual are pretty awesome tools, I have mine set up to run each time I hit Save in VSCode, which means that after I hit Save instead of one long line of JSON I get a formatted JSON instantly.
A holistic solution might require some effort since it should be applied to the most common content-types, so I see why it's probably going to the backlog.
Anyways, again, thank you.
@NghiaTranUIT commented on GitHub (Jan 27, 2020):
Unfortunately, if we add
//, it's not a proper the HTTP Message anymore. Ref: https://developer.mozilla.org/en-US/docs/Web/HTTP/MessagesMaybe the extension of the file is
json, which is automatically created, seems not correct. At the initial implementation, I choosetxt, but some Editors (VSCode) doesn't highlight. Otherwise,jsonext works well.You're right that if I save as a
json, it's not a legit JSON files anymore.I check other tools. Some have the Map Local tool from HTTP Message too, but no highlight, which is really bad for my eyes 👀
@dutzi commented on GitHub (Jan 27, 2020):
Oh, I see... I wasn't aware that there was an HTTP Message standard. Maybe an extension to VSCode (or whatever IDE) might help here. I'll check if one exists for HTTP Message.
Regarding the extension, for syntax highlighting, I'd keep it as
json.@dutzi commented on GitHub (Jan 27, 2020):
No extension for HTTP Message... I guess the best workflow for my use-case would be to delete the request's head, save the file (which triggers prettier), copy the formatted JSON, undo until the request's head is back and paste the formatted JSON over the single-line one.
Update: I found this one it implements an HTTP client in VSCode, and offers syntax highlighting to files with
httpextension. Not very relevant, but still interesting.@dutzi commented on GitHub (Jan 27, 2020):
Will you consider creating two files, one for the HTTP Request's head and another for the body? Is it common practice in other cases?
@yauheniprakapenka commented on GitHub (Jan 27, 2020):
The problem was in the dynamic parameter passed in the request. This is my carelessness.
Thank you for the best proxy in the world!
@NghiaTranUIT commented on GitHub (Jan 27, 2020):
Do you encounter any issue on Map Local @yauheniprakapenka 🤔
@NghiaTranUIT commented on GitHub (Jan 27, 2020):
@dutzi I wouldn't consider to separate into 2 files since it's really cumbersome and increase the complex of the code implementation from me and the end-user too (Since you have to select 2 files in order to change the header and the body).