feat: add slotNode for shell prop

This commit is contained in:
LeoYuan 袁力皓 2022-05-20 14:19:13 +08:00
parent 2f8b9545de
commit d9a44c5de7

View File

@ -43,6 +43,13 @@ export default class Prop {
return Node.create(this[propSymbol].getNode()); return Node.create(this[propSymbol].getNode());
} }
/**
* return the slot node (only if the current prop represents a slot)
*/
get slotNode(): Node | null {
return Node.create(this[propSymbol].slotNode);
}
/** /**
* judge if it is a prop or not * judge if it is a prop or not
*/ */