Comments (6)
Yes, you are certainly correct about both of those attributes. I will not be able to get an opportunity to work on this for a while. If you end up making the changes yourself, we'd be happy to incorporate your code.
from re-com.
Hi, I began working on a pull request and while doing so I ran into the problem of validating XML attribute names. According to the W3 spec here http://www.w3.org/TR/2011/WD-html5-20110525/elements.html#embedding-custom-non-visible-data-with-the-data-attributes the data-*
attribute has to be a valid XML attribute name (not surprising, I guess). I tried implementing the naming spec here http://www.w3.org/TR/REC-xml/#NT-Name using a regular expression, but then found it was exceptionally painful due to JavaScript's poor support for Unicode characters in regular expressions. I could implement it without using a regular expression, but I thought it might be a good idea to ask whether you think it's even worth it to do so, or is it good enough to just make sure the the attribute starts with data-
and has one or more characters after that?
Thanks, and apologies for the bikeshedding
from re-com.
The goal with this validation is to help a programmer catch problems early. Misspelling something can take a surprisingly long time to find sometimes.
So we want to be as helpful as we can be, but not tie ourselves in knots doing it ;-)
In which case, I think checking for data-*
and waving it through as vailid is fine by me.
from re-com.
@meowcakes checking: given you have closed this, are you then working on a patch to wave data-*
through as valid?
from re-com.
Yup, pull request opened here #13
from re-com.
Thanks!
from re-com.
Related Issues (20)
- Tour component demo breaks on clicking "Start Tour!" button HOT 1
- Filter issue when using hiccup for labels in multi-select
- Check-box styling is overridden by browser instead of bootstrap HOT 2
- disabled list should not show on hover background HOT 2
- Conflicting documentation in splits HOT 1
- Datepicker header height increases when a disabled next or previous year button is displayed HOT 1
- Missing icons? HOT 1
- Pass event to popover :on-cancel
- status icon :error has incorrect zmdi-spinner in class
- v-table scrollbar thumb colors are hardcoded (potential PR)
- reagent 1.2.0 reagent.dom/dom-node is deprecated HOT 1
- Bizarre issue with the typeahead component HOT 1
- enhancement: Support :enabled? prop on tab components HOT 1
- horizontal-bar-tabs: Suppress redundant on-click handler calls HOT 3
- Unknown parameter: :parts in tree-select
- Re-com won't build with figwheel-main fig:min HOT 4
- v-table reset! on hover? fails in 2.21.0 but ok in 2.19.0
- simple-v-table: rendering issue/breakage in 2.21.3
- recent changes to v-table still has rendering issues in 2.21.4 HOT 1
- Disabled background colour should be grey in single-dropdown
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 re-com.