Comments (3)
Have a look at the example where we proposed to run load the plugin lazily.
On Nov 7, 2014, at 9:39 AM, mdgbayly [email protected] wrote:
I'm probably missing something really dumb here, but I don't understand the correct way to load this plugin.
The default instructions say just add to your scripts section after bootstrap.
However the plugin contains lots of DOM manipulation code like:$('.alert').attr('role', 'alert')
This runs before our dom is ready so none of these DOM manipulations get applied.
What am I not understanding?
Thanks
Martin—
Reply to this email directly or view it on GitHub #66.
from bootstrap-accessibility-plugin.
Ok, yep, I saw that. But that seems inconsistent with the other instructions that say you can just include bootstrap-accessibility after you include bootstrap. It seems a little unorthodox to require applications to have to implement special lazy loading schemes to correctly use this plugin. Why not include all the DOM manipulation code in some kind of init method that applications could call from their existing jQuery dom ready handlers?
And sorry - this isn't a complaint! Thanks for sharing your code - this type of accessibility functionality is much needed in a shared library. If you think this is an appropriate solution maybe we'll have a go and coding something and sharing back.
from bootstrap-accessibility-plugin.
Just to clarify, although Lazy-loading is an option, if this plugin is not Lazy-loaded, it must be inserted at the end of the <body>
of the document, not in the <head>
; the features do not work if the script is included in the <head>
. The section in the README.md does not make this clear.
I'm surprised that all the initialization in this plugin isn't wrapped in a $(function(){...})
, so it gets run on document ready; am I missing something?
from bootstrap-accessibility-plugin.
Related Issues (20)
- AMD/CommonJS support
- Inappropriate role attributes in dropdowns HOT 1
- Should include jQueryUI license text
- Focus outline when tabbing through navbar HOT 1
- Relationship with bootstrap
- VoiceOver on iPad not work to access modal body HOT 2
- Bootstrap 4 HOT 5
- iframe within modal content not accessible via keyboard
- Uncaught TypeError: Cannot read property 'Constructor' of undefined
- Outdated package on npm HOT 1
- Test
- Modal isn't going back to where it was -BS 3.3.7, 1.0.5 accessibility HOT 4
- Modal not able to tab to new elements due to enforcefocus function HOT 3
- 1.0.5 release? HOT 4
- Collapse is inaccessible by keyboard if all panels are closed by default HOT 2
- Security vulnerability: reliance on EOL jQuery version
- Getting "bootstrap-accessibility.js:637 Uncaught TypeError: Cannot read property 'Constructor' of undefined" some conflict with carousel component. Custom build w/o carousel? HOT 1
- Potential security issue
- Tabindex on accordions HOT 1
- no tooltips HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from bootstrap-accessibility-plugin.