-
Notifications
You must be signed in to change notification settings - Fork 49
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Remove feature detection and hiding of demo's in unsupported browsers #1537
Comments
I'm just a random person, but I took a quick look at this out of curiosity and I think this is okay, unless I'm misunderstanding something. This was added in pull request mdn/yari#759 and seems to use feature detection rather than browser sniffing to display the message. |
Showing how something fails is valuable to web developers, then they can compare the working feature with the degraded experience. Maybe it is better to show this message as a warning together with the demo? |
Moving to mdn/bob, as the feature resides in the editor, and was implemented in #759. |
@romainmenke Can you share what browser and version you saw the red banner with? PS: In the future, please make sure to always use the issue templates to ensure we have all information upfront. |
Hi @caugner, The exact browser nor the version I was on are relevant to this issue. I expect all demo's to be shown regardless of the browser and or version. So I think the change in #759 was not a good direction and should be revisited. It is obviously fine and helpful to indicate that a demo is not fully working in a specific browser, but how a demonstrated web API breaks is useful information for developers. By hiding the demo entirely this information is also hidden. The example from my original post was It shows whether a feature is safe or unsafe to use as a progressive enhancement. |
There is only one issue template, which is focussed on capturing bug report information. https://github.com/mdn/yari/issues/new If there was a template that I could have used which relevant questions, I would have used it. I know how helpful these are and I always try to use them :) |
Let me put some things in context here:
If I understand you correctly, you would prefer that we either
Both options aren't great:
Nevertheless we will ask folks on Discord for their feedback before making a final decision. |
I've changed the title to avoid this point of confusion. If MDN uses client side code to detect feature support then that is what this issue is about. It is the end result, the hidden demo that this issue is about.
That is impossible and doesn't make sense.
Yes, that is what I am trying to communicate here.
That would be confusing when there isn't any context. The combination is possible :)
Showcasing how a feature does not work IS relevant information. Hiding the demo can make a feature seem unsafe to use. A demo with a broken feature that shows the fallback behavior might show to developers that the feature is a harmless progressive enhancement and therefore perfectly safe to use. |
@romainmenke Let me try and ask once more if your argument is theoretical at this point, or whether you can provide a real example where a specific CSS feature is currently not supported in a browser and the interactive examples on the corresponding page is showing that message? That might significantly help your case. |
Initially I filed this issue with Another example : https://developer.mozilla.org/en-US/docs/Web/CSS/ruby-position A codepen that can be used to see the result in all browsers : https://codepen.io/romainmenke/pen/ExGMEGw When the demo is present I can use it to test things out. However when the demo is hidden I can no longer see how it breaks and I can't manipulate the code to try things out. By hidden the (broken) demo I can no longer answer these questions for myself, right there on the page :
Developers can build their own demo's in codepens and use those to try things out. I think that communicating that a demo will not work as expected in the user's browser is a good thing. However I think this can be done without hiding the demo entirely. I also think that the broken/unsupported states of features are valuable to illustrate how something breaks. |
Demo's seem to have browser sniffing and show a red banner when the browser doesn't (fully?) support the demo.
https://developer.mozilla.org/en-US/docs/Web/CSS/hyphens#browser_compatibility
I can not understand why this is needed and who is helped by this?
Also makes me wonder if MDN itself adheres to it's own advice....
https://developer.mozilla.org/en-US/docs/Web/HTTP/Browser_detection_using_the_user_agent
Tasks
The text was updated successfully, but these errors were encountered: