blob: fc71030566770be59a5fd5364f923740138842bd (
plain)
1
2
3
4
5
6
7
8
9
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
);
}
|