I'm sure this question has been asked in another way but I'm asking again as I would like to revisit it.
The help specifically says a MCVE is required for debugging help.
Some questions are still off-topic, even if they fit into one of the categories listed above:
Questions seeking debugging help ("why isn't this code working?") must include the desired behavior, a specific problem or error and the shortest code necessary to reproduce it in the question itself. See: How to create a Minimal, Reproducible Example.
What I find though is that 5 times out of 6 JavaScript questions asking "why isn't this code working?" do not have an MCVE. Often they will only have a link to jsfiddle or codepen. They rarely get closed. They quite often get answered, often with a link to a forked jsfiddle or codepen. Even if they do eventually get closed it's often after an answer in the form of a link to a fork has been posted which just encourages more of the same behavior.
For JavaScript questions Stack Overflow has something called a Snippet which is functionally equivalent to jsfiddle and codepen. If the user had used a snippet their question would likely have it's required MCVE.
AFAIK many users, especially new users, have no idea about this snippet feature. They are both unaware of the MCVE requirement and that their question is therefore off topic. They are also unaware there is a snippet feature and if they had put their code in a snippet it would probably have satisfied the MCVE requirement?
Do we care about this MCVE requirement? If we do is there any way would could encourage users to use a snipping instead of jsfiddle/codepen etc... I know there is (was?) a prompt that comes up saying code is required but I find rarely posts with an actually minimal complete verifiable example. They usually just copy a few lines of code in that may or may not be related to the actual issue and so does not satisfy the MCVE requirement.
I know there is a prompt for jsfiddle/codepen with not code. Unfortunately that prompt is ineffective. Most uses just grab a few lines to shut-up the prompt. They do not add a required MCVE.
Maybe a prompt that if there is a jsfiddle or codepen link actually suggests a snippet and points them to instructions on how to create one with the goal being to get more on topic questions and therefore save everyone time and effort.
As it is the current common flow when it works is
- User posts a JavaScript question with jsfiddle/codepen link an no MCVE, they just paste enough lines to get past the "code please" prompt.
- Someone leaves a comment. Need MCVE. If lucky they vote to close
- User edits post, often still not MCVE since they don't meet the "complete" part
- User gets comment, still not MCVE use a snippet?
- User maybe uses a snippet or maybe just posts more code
- Finally gets answer
That's the common flow right now in my experience when it works. (vs when someone leaves an answer even though the question is off topic)
I wonder if there is a way to make the more common to just be
- User posts question with MCVE (maybe in a snippet since usually covers both the C and the V of mCVe)
- Gets answer
Again: Only for JavaScript questions since snippets currently only work for JavaScript. For non JavaScript questions snippets seem mostly irrelevant.
To put it another way, it seems like a recent goal of S.O. is to me more friendly and I feel unfriendly everytime I vote to close once of these questions and have to leave a comment like "S.O. requires you put the code in the question itself. Consider using a snippet. Sure it's technically not unfriendly but if they had been led to use a snippet in the first place I wouldn't have to leave the commend and vote to close. That would save both of us time.
I also understand that snippets are not a requirement. I'm only suggesting encouraging them since they, more often than not, will solve required MCVE issue for JavaScript questions.
Update:
@Heretic Monkey pointed it's now MRE not MCVE where MRE = Minimal Reproducible Example. The R in MRE is basically a shortcut for what was the CV in MCVE. In other words most users post a jsfiddle or codepen but not enough code to "R"eproduce the issue so my suggestion still stands that encouraging snippets seems like it would yield more on topic questions that need an MRE but are missing one.
Update2:
I am not suggesting all JavaScript questions have a snippet. Rather I'm suggesting
If there are codepen/jsfiddle links that some kind of prompt should encourage a snippet. They are already putting the code online. Why not in the question itself? If they are advanced enough to understand how to ask an on topic question without a snippet they will. But if they're leaving a jsfiddle/codepen link, odds are more often then not their question is off topic by current S.O. definitions of requiring an MRE.
If possible the fact that there is a snippet feature should be called out better. As it is plenty of users, especially new users, have no idea the feature even exists. This is probably especially important in the guided question form.
Update 3:
Posting screenshots (since they might be edited) of examples of questions which if the user could have been directed to use a snippet the question would likely have been on topic
-
Code in question. Code does not repo issue. Link to pen that does. So it's off topic. If they had used a snippet it wouldn't be. My time wasted, their time wasted, fail for S.O. being helpful.
-
no code in question, link to pen, legit question, if pen was a snippet would be on topic.
-
another. some code in question but repo not in question