enonic / lib-guillotine

Apache License 2.0
3 stars 0 forks source link

Add the `site` value to ContentPathType #203

Closed anatol-sialitski closed 2 years ago

anatol-sialitski commented 2 years ago

https://github.com/enonic/lib-guillotine/issues/192#issuecomment-983521723 Add the site value to ContentPathType.

After that ContentPathType supports two options:

rymsha commented 2 years ago

I have written my concerns about "site" ConttentPathType here

All graphql client libraries support schema transformation. So there is no need to complicate our API with trivial transformations

sigdestad commented 2 years ago

Is schema Transformation equivalent to data Transformation?

rymsha commented 2 years ago

Yes:

Other use cases for a read function include:

  • Transforming cached data to suit your client's needs, such as rounding floating-point values to the nearest integer
  • Deriving local-only fields from one or more schema fields on the same object (such as deriving an age field from a birthDate field)
  • Deriving local-only fields from one or more schema fields across multiple objects
sigdestad commented 2 years ago

Beautiful.

anatol-sialitski commented 2 years ago

Maybe in this case we can get rid of the type argument in the _path field?

rymsha commented 2 years ago

I'd keep some room for improvement, if we already have it. Just in case.