Replies: 1 comment
-
@adecusati the grammar specifies the mixins must be multi-line:
|
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I am working with Backstage. I have a schema for JSONSchema and for UISchema. Backstage templates use a schema that is basically jsonschema merged with uischema. How would i create a schema that works like this in KCL that includes validations from both the uischema and json schema modules?
It seems to me that i should be able to create two mixins that inherit these base schemas, but maybe i am misunderstanding something. If i define the following base schemas - with the idea that I cannot modify these directly (representing the json and ui schemas):
I create a third schema and mix these in as follows:
If i try to create an object that uses
T
schema, I cannot seta
orb
or else i get "Cannot add member 'a' to schema 'T'". However, it works if i move the definition ofa
into AMixin directly, or if i instantiate AMixin instead of T. Should this not work? How else can this situation be handled? Ideally, I dont have to replicate the entire schema definition a second time...Beta Was this translation helpful? Give feedback.
All reactions