thunderclient / thunder-client-support

Thunder Client is a lightweight Rest API Client Extension for VS Code.
https://www.thunderclient.com
Other
3.62k stars 127 forks source link

Would be nice to enable/disable body types besides the forms. #1587

Open angrodm opened 1 month ago

angrodm commented 1 month ago

Please describe feature/problem details and the solution you'd like. The Form and Form-encode tabs of the Body section for a request allow you to enable/disable the individual fields. It would be nice to be able to have a checkbox on the other Tabs that provides the functionality for them. For example I have a large JSON body that is optional for a request I need to send. Sometimes I send the body, other times I do not. It would be nice if I could put the body in and just use a checkbox to enable or disable the entire JSON body.

Describe alternatives you've considered I considered trying to write a script to set the body and using an environment variable to determine whether the Pre Run script sets the body or not. Other options I considered is having two requests, one with the body filled out, and another without the body. Lastly I considered adding the Body to the Docs setting so that I can quickly copy / paste it into the JSON tab when I need the body and delete it when I don't.

Are you using the free version/paid version/trial: I am using the free version.

rangav commented 3 weeks ago

Thanks @angrodm for the feedback, Will review it.