Just another example of why when people use frameworks like bootcrap, my advice is to go find a stick to scrape it off with. Given the endless gibberish DIV for nothing, tabindex on elements that can't even accept focus, pointless aria role bespeaking presentational thinking, endless pointless classes for NOTHING, being at H5 depth which for a dialog makes no sense given there's likely no H4 for it to be starting a subsection of preceding it, and the use of buttons and JavaScript for what hash links and the :target attribute could do without a single blasted line of JavaScript.
But then given my opinion of React, its no surprise to me dev's using it would dive for this type of broken, inaccessible, non-gracefully degrading rubbish coding methods.
Seriously, code like this tracks brown smelly stains across the web's carpets. That's not on you, that's on the sleazy scam artists spewing unfounded propaganda about how "great" these frameworks are, CREATING trash like bootcrap or failwind whilst being utterly devoid of the most basic knowledge of HTML or CSS.
And they don't slop display:none in there making the content invisible to search engines looking for content cloaking. The safe function not needing to close it, just let the href="#" do it's job to close it. Opening the modal being as simple as either doing href="#sampleModal" on an anchor, or setting the hash on Window.history. EVERYTHING else handled by the CSS, not the scripting.
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
Just another example of why when people use frameworks like bootcrap, my advice is to go find a stick to scrape it off with. Given the endless gibberish DIV for nothing, tabindex on elements that can't even accept focus, pointless aria role bespeaking presentational thinking, endless pointless classes for NOTHING, being at H5 depth which for a dialog makes no sense given there's likely no H4 for it to be starting a subsection of preceding it, and the use of buttons and JavaScript for what hash links and the :target attribute could do without a single blasted line of JavaScript.
But then given my opinion of React, its no surprise to me dev's using it would dive for this type of broken, inaccessible, non-gracefully degrading rubbish coding methods.
Seriously, code like this tracks brown smelly stains across the web's carpets. That's not on you, that's on the sleazy scam artists spewing unfounded propaganda about how "great" these frameworks are, CREATING trash like bootcrap or failwind whilst being utterly devoid of the most basic knowledge of HTML or CSS.
Check this out, simple page but the menu modals don't use a line of JS.
levelup.gitconnected.com/modal-dia...
Which is why there's likely little reason for the markup of a modal like yours to differ from:
And they don't slop display:none in there making the content invisible to search engines looking for content cloaking. The safe function not needing to close it, just let the href="#" do it's job to close it. Opening the modal being as simple as either doing href="#sampleModal" on an anchor, or setting the hash on Window.history. EVERYTHING else handled by the CSS, not the scripting.