Is dynamic DOM building 508 complaint?
Asked Answered
M

3

14

With more and more people using things like Backbone, Ember and other JS MVC type frameworks, more and more HTML DOMs are being built dynamically with the first HTML page only containing a "root" element to dump the generated HTML into.

Is this practice 508 complaint?

Molotov answered 30/11, 2012 at 0:54 Comment(5)
That would be a question to be addressed for each specific framework, would it not? (I don't know enough about Section 508 to know if it even can be addressed, or if compliance would depend on a site's use of a given framework)Hrutkay
Kind of depends on how you choose to use the frameworks...Homosexual
Let me rephrase the question to dynamic DOm building.Molotov
DHTML is not evil. Used properly with the WAI Accessible Rich Internet Applications standards, it should be no problem. I don't know about that american law, though.Saltine
No, they are not (assuming that is the only way you are delivering content). But 508 is severely out of date and currently being revised (see my comment to Davis's answer below.Pounds
M
3

Presumably as long as there is a way for everyone to access whatever information you are supplying, then yes. If you are relying entirely on JavaScript to provide said information, then I would guess no, since not everyone has JavaScript enabled. Section 508 requires <noscript> tags that provide the ability to get the information in by other means because not all assistive technology can access the same. That seems to be the general way these things work (the W3 Accessibility guidelines emphasize that, and the 508 standards, specifically those on equivalency, seem to say much the same).

So the presentation doesn't have to be the same, as long as the experience is "comparable", according to the 508 standards. But I would think that if the presentation relies on JavaScript (and dynamic DOM building requires JavaScript), the experience would not be comparable, and thus you would have to provide an alternative HTML-only version of the site.

May answered 30/11, 2012 at 1:17 Comment(7)
Note that WCAG 1 (like section 508) is severely out of date. WCAG 2 doesn't have the draconian rules against JavaScript that 508 and WCAG 1 do. The Section 508 rules are currently under revision and will probably end up more in line with WCAG 2, which IMO is the best target these days.Pounds
Wow, you're right... it's been a while since I read the thing, to my shame. I'll read up on it some more and hopefully come back with a better answer :-/ Cheers!May
@DavidJohnWelsh: To be technically correct, JavaScript is not required for dynamic, clientside DOM building - there are other technologies, too. Of course those would qualify as "inaccessible" with any criteria :-)Saltine
@Saltine Ah, yes, but the only real technology for doing it is JS. (Being as I am a web developer, of course, "real" in this instance is defined as "the technology that I use and like and therefore think is better than anything else, including things I may not even know exist" ;-) )May
Man, I never know what to do with an emoticon when a parenthesis must follow it...May
@Pounds your comment is slightly misleading. Yes 508 is out of date, if the OP is designing this for the government, they must follow 508 vs WCAG 2. They are free to do WCAG 2 as long as the S508 standards are met first because agencies are required to do it by law, and are audited by DoJAronow
@RyanB good point. If you are mandated to meet 508 you have no choice. Leaves developers in an awkward position at the moment. Current 508 rules are out of touch with the realities of the web and users yet still must be followed by some. Probably the best way to satisfy that is with both client and server side rendering.Pounds
I
3

It all depends on how you do it. I can take a system that's supposed to be 508 compliant (like Plone) and make it completely non-compliant.

If you want to make dynamic sites, I recommend looking into WAI-ARIA. It's part of the official HTML5 spec, and is supported by all major browsers.

In short, WAI-ARIA works by allowing the developer to add a role attribute to a tag. For example, you can give a tag the 'alert' role, if it's something that would pop-up on a page. You can combine roles with CSS and JS to create applications that can be used by individuals with a variety of disabilities.

Illgotten answered 2/12, 2012 at 20:59 Comment(0)
S
1

I believe, so long as you provide a static version of your webpage, then it should be complaint. MVC and MVVC websites contain AJAX content and, by default, they use JavaScript to push and pull the information on the page as well as construct the DOM. This alone isn't enough, but If you follow the guidelines for providing an indexed version of your website then you can have a full static representation of each page. Those pages are pages that you would want a search engine to see (this would essentially be the same as the public). Follow this approach and theoretically it should work.

Here's some more info about how this works with a MVC JavaScript framework called AngularJS: http://www.yearofmoo.com/2012/11/angularjs-and-seo.html

Shimmery answered 30/11, 2012 at 1:45 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.