Stack Overflow offers a great snippet tool to add HTML/JS/CSS to questions and answers, but sometimes we just want to try different test-cases to someone else's snippets or run whatever quick tests we desire.
Today, the way we can achieve that is by clicking the button "Copy snippet to answer" and there we can tweak and test the code. But that's not ideal because:
- It automatically creates a draft of an answer that will never become an actual answer;
- Doesn't work if the user already answered that question or if the question isn't accepting answers.
The snippet editor is a powerful lightweight tool that runs in the client-side only, so I think it would be awesome to have quick unrestricted access to this tool to run quick tests in other people's codes.
My proposal is
...replacing the button "Copy snippet to answer" with the button "Edit snippet" (or another wording). This new button will open the snippet editor with the current code, allowing the user to freely tweak with it.
In this case, the button "Save & insert into post", will instead have the words "Save & add to answer" for clarification.
This also saves a step to people who actually wants to add an answer using other people's snippets, because currently they have to click "Copy snippet to answer" and then "edit the above snippet" for the same result.