1

Question
Is it 'acceptable' to post jQuery code for an answer which is tagged [twitter-bootstrap] but not [jquery] nor [javascript]?


Scenario (for context)

• Today I answered a question which had the following tags: (html, css, html5, twitter-bootstrap, css3).

• A second user posted an answer which contained a large chunk of jQuery code.

• I comment on the answer with: "jQuery was not tagged in the OP. "

• A third user (~39k rep) then comments on my answer with: "Well, it wasn't tagged Flexbox either...."

• A 'discussion' pursues about this...

• I ask the third user: "Which tag does jQuery fall under in this case which makes it a viable answer?"

• Third user: "It falls under Bootstrap, which use script"


Now I sort of get what the 3rd user is saying, as jQuery is commonly found in conjunction with Bootstrap, however, I use Bootstrap for Angular and not an ounce of jQuery, so when I saw that collection of tags my assumption was a pure HTML / CSS approach.

So is it acceptable to post jQuery answers for [twitter-bootstrap] tagged questions even though the javascript nor jQuery tag was explicitly included?


Honestly, the feedback is not what I expected, and is in favor of jQuery being an acceptable answer. If that is the case, then should the tag wiki be edited to actually include a reference to jQuery.

18
  • Not knowing a lick of [twitter-boostrap], I will say that for [unity3d] questions, I would accept answers posted in C# or JavaScript (<cough, UnityScript>) regardless of what the question was tagged as just because the differences between the two are relatively minor and any decent programmer can convert from one to the other with little more than two regex replacements. I converted an entire project once. Commented May 31, 2017 at 14:48
  • @Draco18s In that case I would agree with you, however these are 2 very different languages and approaches. It would be like getting C# code for a question with tags: [unity3d] [shader] and your question only includes hlsl.
    – Zze
    Commented May 31, 2017 at 14:59
  • @Zze Fair point. :) Ironically I was trying to get a particular post-processing effect in Unity a couple days ago and couldn't for the life of me figure out how to do it as a shader. But C#? Pfft, easy. Downside: it has to pipe data off the GPU to do some CPU computation and pipe it back. And crash a lot for allocating over 1.6 GB of ram... Commented May 31, 2017 at 15:05
  • @Draco18s RIP RAM... Should've written a ComputeShader for that bad boy.... Honestly though, if the consensus is that it is acceptable then I am 100% fine with that.
    – Zze
    Commented May 31, 2017 at 15:11
  • 1
    @Zze Oh, definitely should be a compute shader, I just haven't been able to figure it out. :D And for a quick-and-dirty project to support an answer on World Building I wasn't terribly concerned. Commented May 31, 2017 at 15:14
  • 2
    Of course it's acceptable to give a jquery answer to a twitter bootstrap question. It would even be acceptable to give an angular answer, or react, or php. Whether or not the answer would be useful, however, is an entirely different question. Vote often and appropriately.
    – Kevin B
    Commented May 31, 2017 at 17:21
  • @KevinB nope, not PHP. This isn't in the scope of the question, answering with the wrong tool/langage to the question, is the same that answering a question with the same tool but not the question. What make JQuery acceptable here is that you need jQuery to have bootstrap working, so if you can't in angularJS you can "downgrade back" to jQuery. Of course a vanilla JS answer would still be interesting.
    – Walfrat
    Commented Jun 1, 2017 at 13:06
  • 2
    @Walfrat it would still be an answer. it would be invalid to flag it as not an answer, and if it's well formed it would likely survive a low quality flag.
    – Kevin B
    Commented Jun 1, 2017 at 14:14
  • @KevinB I disagree, what determine a question on SO (IMHO) is : does it respect it's scope : the question AND the stack. If you go totally outside of one or another, it's not an answer IMHO. Otherwise I should try to whore rep by giving Java answer to every question in all langages. But I'am pretty sure that I won't last long if I try whatever the quality of my answer is.
    – Walfrat
    Commented Jun 1, 2017 at 15:12
  • 2
    @Walfrat right. but it's still an answer. it isn't "not an answer". it may or may not be low quality, but the quality of the answer is unrelated to the programming language (or lack thereof) used in the answer. it's still an answer. it's "acceptable". it may not be a good/useful/clear answer, or a correct answer, but it's still an acceptable answer. Even acceptable answers are often worthy of being downvoted.
    – Kevin B
    Commented Jun 1, 2017 at 15:28
  • @PeterMortensen - Off topic, but what does the "active reading" note you use in your edit summaries mean?
    – BSMP
    Commented Jun 1, 2017 at 18:59
  • @KevinB so just to clarify your last comment, ignoring all tags and answering with any language you want, as long as it is thorough and well formatted make it an acceptable answer...?
    – Zze
    Commented Jun 1, 2017 at 21:53
  • depending on what you mean by acceptable answer, yes. To me an acceptable answer is one that doesn't have a flag that applies to it. it's not spam, it's not rude/offensive, it's not a comment, and it's an answer, correct or wrong, useful or not useful.
    – Kevin B
    Commented Jun 1, 2017 at 21:57
  • 1
    then what was the purpose of this question? what would you expect to happen to an answer that doesn't meet your requirements but otherwise a perfectly valid post?
    – Kevin B
    Commented Jun 1, 2017 at 23:27
  • 2
    My point is you can answer with whatever you want, as long as your answer is an answer and doesn't fall under one of the flag reasons. The usefulness and quality of the answer will (hopefully) be judged via votes. If you post an answer that doesn't address the question, the chances of said answer being poorly received are increased.
    – Kevin B
    Commented Jun 1, 2017 at 23:31

1 Answer 1

2

So is it acceptable to post jQuery answers for [twitter-bootstrap] tagged questions even though the javascript nor jQuery tag was explicitly included?

It is not wrong to suggest a solution to the question which the asker might not have considered or even known about. Nor is it wrong to suggest a correct solution that may ultimately not work for the OP but could for others facing the same/similar problem.

Consider this comment from your post:

A 3rd user (~39k rep) then comments on my answer with: "Well, it wasn't tagged Flexbox either.

They do have a point here. I don't know if the OP specified which browsers they have to support (they usually don't), but if they're supporting IE11 a flexbox solution might not work for them.

On the other hand, maybe they OP was simply unfamiliar with flexbox or didn't think it would solve their problem.

Either way, a flexbox solution is likely to work for someone else who sees the question later. Just like a jQuery solution would work for many people using Bootstrap.

That's not to say that this particular answer was good or useful or that all languages/frameworks/libraries are equally useful solutions to all problems. But it isn't unacceptable just because it wasn't included in the tags.

If an asker has to do something without X or can only do something with X they can specify that in the title and/or the post itself.

(Note that requiring the tag to exist to use it in an answer directly contradicts the advice we give people who want to ask if a library/framework exists for their task: Describe the problem and what you've done so far and if a tool exists that would help you, someone will probably point it out in an answer. If they had to tag with whatever they wanted an answer to use, this wouldn't be possible.)

4
  • 1
    I think you make some good points in this post, except for the part about flexbox. Flexbox is a css3 property - css & css3 were both tagged in the OP
    – Zze
    Commented Jun 1, 2017 at 13:46
  • @Zze I've seen posts where a user wanted to use a CSS3 property only to find out that they were supporting browsers that had no/limited support for the property.
    – BSMP
    Commented Jun 1, 2017 at 14:59
  • I'm not sure what point that comment was trying to make?
    – Zze
    Commented Jun 1, 2017 at 23:41
  • @Zze I thought that when you said that you disagreed, that you meant the idea that a flexbox solution might not work for them. Was I wrong?
    – BSMP
    Commented Jun 2, 2017 at 2:02

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .