-
Notifications
You must be signed in to change notification settings - Fork 12
[DPF]: Adjusted hover visualization transformer definition and added hook for subscribing to WorkbenchServices
#1006
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
base: main
Are you sure you want to change the base?
[DPF]: Adjusted hover visualization transformer definition and added hook for subscribing to WorkbenchServices
#1006
Conversation
WorkbenchServicesWorkbenchServices
Anders2303
left a comment
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.
LGTM
| type KeysMatching<T, Pattern extends string> = { | ||
| [K in keyof T]: K extends Pattern ? K : never; | ||
| }[keyof T]; | ||
|
|
||
| type PickMatching<T, Pattern extends string> = { | ||
| [K in KeysMatching<T, Pattern>]: T[K]; | ||
| }; | ||
|
|
||
| export type HoverTopicDefinitions = PickMatching<GlobalTopicDefinitions, `global.hover${string}`>; |
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.
Instead of doing this, wouldn't it be easier to just split up the type in WorkbenchServices instead?
export type GlobalHoverTopicDefinitions {
"global.hover...": ...;
// ...
}
export type GlobalSyncValueTopicDefintions {
"global.syncValue...": ...
// ...
}
// etc...
export GlobalTopicDefinitions = GlobalHoverTopicDefinitions & GlobalSyncValueTopicDefintions & ...|
@Anders2303 and @rubenthoms to check if still relevant. |
No description provided.