Skip to content

Commit

Permalink
Fix cloneElement Typescript definition (#1197)
Browse files Browse the repository at this point in the history
* Fix cloneElement Typescript definition

The cloneElement function accepts an optional third argument to override the cloned element's children.
  • Loading branch information
hiddedejong authored and marvinhagemeister committed Aug 25, 2018
1 parent 2e53084 commit cb67a81
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/preact.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,7 @@ declare namespace preact {

function render(node: ComponentChild, parent: Element | Document | ShadowRoot | DocumentFragment, mergeWith?: Element): Element;
function rerender(): void;
function cloneElement(element: JSX.Element, props: any): JSX.Element;
function cloneElement(element: JSX.Element, props: any, ...children: ComponentChildren[]): JSX.Element;

var options: {
syncComponentUpdates?: boolean;
Expand Down

0 comments on commit cb67a81

Please sign in to comment.