You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The SLD parser (or specifically the underlying xml2js library) does not properly support element order. For reading this could work if we'd use the appropriate xml2js options, but for writing these are not supported. This means that writing out a style like this may rearrange elements. Example:
This is currently the only place I can think of where it might cause problems, but once we'll support functions which get a list of parameters this will cause problems.
It's also not very nice on the filter level because filters of the same type on the same level will always be grouped together, regardless of the original definition.
IMHO we should switch to a different way of XML generation.
The text was updated successfully, but these errors were encountered:
I was looking at libraries to parse XML before I stumbled on the geostyler suite of libs. I'm not sure if fast-xml-parser solves the problem here in the issue, but it does seem to be much more performant than xml2js. Just throwing it out there
PARSER
SLD
BUG
Description:
The SLD parser (or specifically the underlying xml2js library) does not properly support element order. For reading this could work if we'd use the appropriate xml2js options, but for writing these are not supported. This means that writing out a style like this may rearrange elements. Example:
Paste this in the demo, switch to SLD, copy the SLD, reload and paste the SLD back in and you'll get:
This is currently the only place I can think of where it might cause problems, but once we'll support functions which get a list of parameters this will cause problems.
It's also not very nice on the filter level because filters of the same type on the same level will always be grouped together, regardless of the original definition.
IMHO we should switch to a different way of XML generation.
The text was updated successfully, but these errors were encountered: