export const enum ShapeFlags {
ELEMENT = 1,
FUNCTIONAL_COMPONENT = 1 << 1,
STATEFUL_COMPONENT = 1 << 2,
TEXT_CHILDREN = 1 << 3,
ARRAY_CHILDREN = 1 << 4,
SLOTS_CHILDREN = 1 << 5,
TELEPORT = 1 << 6,
SUSPENSE = 1 << 7,
COMPONENT_SHOULD_KEEP_ALIVE = 1 << 8,
COMPONENT_KEPT_ALIVE = 1 << 9,
COMPONENT = ShapeFlags.STATEFUL_COMPONENT | ShapeFlags.FUNCTIONAL_COMPONENT
}
当然肯定没说全,但也说的差不多
8. 手写洗牌算法以及匹配模板字符串的`${}`,比如说'afsasf safasf${a} asfasf ${b}'要你匹配到${a}与${b}的内容
总体而言感觉还是挺简单的
======================
一面就OC了,不过给的太少了就拒了
#知乎##前端##前端面试#