-
Notifications
You must be signed in to change notification settings - Fork 597
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: React config component composition #27899
feat: React config component composition #27899
Conversation
a1a5c74
to
e3f21d0
Compare
0360703
to
b4602a5
Compare
a3b1a61
to
2df6ce2
Compare
140bbd7
to
d1d7a84
Compare
f96b283
to
87494e5
Compare
a829759
to
652e4b9
Compare
}; | ||
|
||
const Item = Object.assign<typeof _componentItem, NestedComponentMeta>(_componentItem, { | ||
componentType: "option", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
componentType: "option", | |
componentKind: "option", |
There is always mess with the word type
in metadata, need to be careful when using it to avoid misunderstanding.
We're using TypeScript inspired word "kind" for such cases as this one.
A "type" is a TypeScript type and a "kind" is a specificator of a variation.
In this example Shape
is a type (TypeScript-world type), and 'circle' | 'square' | 'triangle'
is a kind (variation specificator)
type Shape =
| { kind: "circle"; radius: number }
| { kind: "square"; x: number }
| { kind: "triangle"; x: number; y: number };
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we please leave this rename to a follow-up PR to avoid the need to re-release generators
right now?
|
0edb1c0
to
d2f8c81
Compare
82cad50
to
2c21d42
Compare
…ponents, add HOC function
2c21d42
to
563e725
Compare
No description provided.