It would be better if the response could be just a normal document with highlighting.
Then we could use the full power of VS Code to search, select or manipulate the result data without having to copy and past into a new document.
@dakaraphi using html to preview response instead of normal text document is by design for following reasons.
highlight.js packageAnd I know, what you've mentioned like __search__ and __manipulate__ is a pain point of html page in the limitation of vscode.
However, copy and paste is not needed in my tool, since you can simply do this by clicking the Save Response button in the upper right corner

@Huachao I'm not asking you to change the current behavior, I'm asking for an option to be provided to choose to dump the data to an editor, ideally with the language set by the response content type.
So, it would just be nice to have a new command to send request and dump to editor.
@dakaraphi Got, I will reopen this and consider this carefully. Thanks for your suggestion
So, after spending some more time using this extension, this is my typical workflow
So if there was a command that basically automated that workflow, that would be awesome.
@dakaraphi I understand your pain now 馃槃 .
@dakaraphi I have fixed this issue, and will publish in next release. When you click the newly added 'Save Response Body' icon, the extension will save body __ONLY__ according to content type to corresponding file extension. And you can also override the content type and file extension mapping rule, like by default, I will set the content type of application/atom+xml to file extension atom, and you can overwrite in setting to xml
@Huachao Thanks for taking a look into this so quickly! This sounds a bit better, but not exactly what I was attempting to describe above. Could you please consider the following?
@dakaraphi I will think about you requirement again. And the save body to specific file extension is required by other user, so I will keep it.
@dakaraphi I have implemented this, and after I published the version, you can experience this by set the flag rest-client.previewResponseInUntitledDocument to true. And after that, you can still use previous send request command, and view response in an untitled document.
@dakaraphi I know you already provide a new PR and I also leave some comments to discuss with you. And I want to tell you that the new version 0.13.0 is already published, and you can use the functionalities except your suggestions.