diff options
author | tg(x) <*@tg-x.net> | 2016-10-05 00:02:10 +0200 |
---|---|---|
committer | tg(x) <*@tg-x.net> | 2016-10-05 00:02:10 +0200 |
commit | ec62d29c90958aa8d41474ed2fe5a179d6fafed7 (patch) | |
tree | 367cc55bc6772cf194ed6c4778cd344d581d3d7c /thirdparty/preact/src/clone-element.js | |
parent | fda241d74d5c1c39203b64da676c684d4dc9d800 (diff) | |
parent | d3ccf4103900b8d990b1970d135695b938d94eae (diff) |
Merge branch 'master' of taler.net:/var/git/wallet-webex
Diffstat (limited to 'thirdparty/preact/src/clone-element.js')
-rw-r--r-- | thirdparty/preact/src/clone-element.js | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/thirdparty/preact/src/clone-element.js b/thirdparty/preact/src/clone-element.js new file mode 100644 index 000000000..fc7103056 --- /dev/null +++ b/thirdparty/preact/src/clone-element.js @@ -0,0 +1,10 @@ +import { clone, extend } from './util'; +import { h } from './h'; + +export function cloneElement(vnode, props) { + return h( + vnode.nodeName, + extend(clone(vnode.attributes), props), + arguments.length>2 ? [].slice.call(arguments, 2) : vnode.children + ); +} |