Skip to content

Data traversal? #12

@madeleineostoja

Description

@madeleineostoja

Allow simpla-paths to traverse up/down the tree in attributes, using dot notation inside SIDs/GIDs. Fixes the use-case where markup structure doesn't perfectly match content structure, especially with shared code and complex content models

  • foo.bar to traverse down a tree

  • ..baz to traverse up a tree (additional dot for each level up)

  • Can combine patterns, eg: ..baz.qux

  • Can traverse in both SIDs and GIDs (obvs GIDs can only traverse down, useful for removing unecssary nesting)

  • If the key accessed with traversing doesn’t exist, it is created as per usual

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions