Symbol
export const REACT_ELEMENT_TYPE = hasSymbol? Symbol.for(‘react.element’):0xeac7;
Symbol.for(‘react.element’)用字符串’react.element’产生一个symbol类型的值,symbol类型的值一般用作对象的匿名属性。
Symbol
export const REACT_ELEMENT_TYPE = hasSymbol? Symbol.for(‘react.element’):0xeac7;
Symbol.for(‘react.element’)用字符串’react.element’产生一个symbol类型的值,symbol类型的值一般用作对象的匿名属性。
发表回复