Skip to content

Ability to declare a container as both @index and @set #269

Closed
@lrowe

Description

@lrowe

I have the following indexed data structure that I'd like to preserve during compaction:

{
  "dbxref": {
    "db1": ["term1"],
    "db2": ["term2a", "term2b"]
  }
}

Declaring a context with @container: @index partly works, but I also want to preserve the array even when it has only a single member:

{
  "@context": {
    "@vocab": "http://localhost/context#",
    "dbxref": {
      "@container": "@index"
    }
  },
  "@id": "http://localhost/item1",
  "dbxref": {
    "db1": "term1",
    "db2": ["term2a", "term2b"]
  }
}

It would be helpful to have some way to declare a container as both @index and @set.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions