-
Notifications
You must be signed in to change notification settings - Fork 39
Conversation
src/customElements.ts
Outdated
@@ -102,6 +108,11 @@ export interface CustomElementDescriptor { | |||
* Initialization function called before the widget is created (for custom property setting) | |||
*/ | |||
initialization?: CustomElementInitializer; | |||
|
|||
/** | |||
* |
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.
jsdoc
src/customElements.ts
Outdated
|
||
export type DomToWidgetWrapper = Constructor<WidgetBase<DomToWidgetWrapperProperties>>; | ||
|
||
export function DomToWidgetWrapper(domNode: CustomElement): DomToWidgetWrapper { |
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.
add some jsdoc
815df67
to
65a239b
Compare
@@ -60,6 +61,11 @@ export interface CustomElementInitializer { | |||
(properties: WidgetProperties): void; | |||
} | |||
|
|||
export enum ChildrenType { |
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.
Just a question/random thought... for HNode and VNode we use symbols to tag the types, here we are using string enums. Conscious decision or unconscious?
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.
It was conscious as an enum
seemed more appropriate as part of a consumer API
Type: feature
The following has been addressed in the PR:
Description:
For custom elements that are written to deal with Dojo 2 custom element children only, add support for widget-core to treat them as widgets meaning that they can be authored without needing to add specific code to deal with custom elements.
Enabling usage as follows:
Using as a Dojo Widget:
Using as a Custom Element: