Open mrkvon opened 1 year ago
@mrkvon Yes, this feature is not currently implemented. There are a few workarounds. You could copy the external shape into your .shex file, or you could manually define your types and JSON-LD context.
@jaxoncreed
Let me just clarify: we already copied external shapes to the project folder. We're trying to reference a shape from other file in the same folder of the project (not external shapes from e.g. shaperepo). Is that also not supported currently?
In any case, to resolve this we've copied all shapes into a single file (WIP), and it works. The downside is the shapes may be harder to maintain and reuse, as i already wrote.
With ldo-cli, in shex file, can we reference a shape defined in other shex file?
Something along the lines of
With such setting, the solidProfile.typings.ts didn't get generated, but failed with error like
Am i missing something, or is this currently not possible?
Motivation
I'm trying to figure out a good way to query Solid data across multiple documents, and i'd like to use LDO because of its awesome shape-based type safety.
One idea i want to try: fetch all relevant documents[^1], create rdf dataset from them, and then use LDO on the dataset, to access the results easily. For this, multiple related shapes would need to get chained together, so we could do
[^1]: At the end, this may be a bit more complicated. We could fetch new relevant documents as we follow our nose through the rdf graph according to query (whatever that may look like)
Of course we could put all the shapes into a single file. But that would be a bit hard to maintain or reuse...