-
-
Notifications
You must be signed in to change notification settings - Fork 111
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
refactor(common): Consider moving from xml2js to fast-xml-parser #12208
Comments
FWIW I use fast-xml-parser in https://github.com/unicode-org/cldr/tree/main/docs/charts/keyboards for those charts. But this is a simplistic use that is not attempting to validate. Our json validation is separate from the xml validation, though, so that should not be an impact. fast-xml-parser is at least currently maintained! |
- need to use trimValues:false and a custom tagValueProcessor to preserve spaces Fixes: #12208
- difference in fast-xml-parser and xml2js handling here - part of the move to fast-xml-parser Fixes: #12208
turns out we didn't have a test for XML NCR in keyboards. Now we do. Fixes: #12208
- help make the parsed form identical across platforms Fixes: #12208
Subsystems changed: - ldml keyboard reader (main and test) - kpj - kvks - kmp compiler test: made the test-xml-utils less verbose about the pathnames Fixes: #12208
- declarative syntax for options - workaround an issue where xml2js is mutating our options objects - improve tests Fixes: #12208
- writer passes kvks tests - two small changes: allow " for XML generation, and also the same XML prologue as the actual .kvks files. Fixes: #12208
I had split the PRs so that this isn't actually fixed, yet. |
- because of the form to="" in ldml, we need to distinguish attributes and sub-elements in the ldml xml parsing - use an attributePrefix, and fixup the object tree afterwards Fixes: #12208
Consider moving from xml2js to https://www.npmjs.com/package/fast-xml-parser?
Originally posted by @mcdurdin in #8616 (comment)
This arose again in discussions on kmc-convert
@srl295 we should discuss
The text was updated successfully, but these errors were encountered: