Proposed tweak to marker JSON format: Move type outside of data, into its own column
The schema of a marker is currently indicated by a type property on the data object of a marker.
It would be nice if the type was stored outside of the data object. This would mean that type is no longer a reserved key name that cannot be used for fields, so it would avoid bugs like bug 1939499.
My proposal is:
- Move the
data.typevalue out of thedataobject, into a separate marker tabletypecolumn. - Optional: Instead of a string, make it an integer which indexes into the global marker schema array.
Edit 2025-01-06: I rewrote this comment to mention the collision issue and removed the Rust API justification
┆Issue is synchronized with this Jira Task
This could also make "type" a normal field name inside the data object (more than once when adding a new marker I tried to have a "type" field and that ended up messing with the marker schema used by the front-end).