ce-la-react
Advanced tools
Comparing version 0.1.0 to 0.1.1
@@ -28,3 +28,3 @@ /** | ||
export type ElementProps<I> = Partial<Omit<I, keyof HTMLElement | 'connectedCallback' | 'disconnectedCallback' | 'attributeChangedCallback' | 'adoptedCallback'>>; | ||
export type ComponentProps<I, E extends EventNames> = Omit<React.HTMLAttributes<I>, keyof E | keyof ElementProps<I>> & EventListeners<E> & ElementProps<I>; | ||
export type ComponentProps<I, E extends EventNames = {}> = Omit<React.HTMLAttributes<I>, keyof E | keyof ElementProps<I>> & EventListeners<E> & ElementProps<I>; | ||
/** | ||
@@ -107,3 +107,3 @@ * Type used to cast an event name with an event type when providing the | ||
*/ | ||
export declare function createComponent<I extends HTMLElement, E extends EventNames>({ react: React, tagName, elementClass, events, displayName, toAttributeName, toAttributeValue, }: Options<I, E>): React.ForwardRefExoticComponent<React.PropsWithoutRef<ComponentProps<I, E>> & React.RefAttributes<I>>; | ||
export declare function createComponent<I extends HTMLElement, E extends EventNames = {}>({ react: React, tagName, elementClass, events, displayName, toAttributeName, toAttributeValue, }: Options<I, E>): React.ForwardRefExoticComponent<React.PropsWithoutRef<ComponentProps<I, E>> & React.RefAttributes<I>>; | ||
export {}; |
{ | ||
"name": "ce-la-react", | ||
"version": "0.1.0", | ||
"version": "0.1.1", | ||
"type": "module", | ||
@@ -5,0 +5,0 @@ "description": "Create a React component from a custom element.", |
19477