We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
在控制台看,高亮的就是可枚举的,哈哈
举例举例:
function Parent() { this.name = 'lvlei'; } Parent.prototype.show = () => { console.log('show'); } let parent = new Parent(); console.log(parent);
可以只直观看出,name和show字段是可枚举(高亮)的嘛
name
show
class Parent { constructor() { this.name = 'lvlei'; } show() { } } let parent = new Parent(); console.log(parent);
可以只直观看出,name字段是可枚举(高亮)的,而show是不可枚举(没高亮)的~
支持浏览器
The text was updated successfully, but these errors were encountered:
No branches or pull requests
举例举例:
ES5构造函数创建实例对象:
可以只直观看出,
![image](https://user-images.githubusercontent.com/25945338/48967176-9f295400-f017-11e8-9e60-0cf1a8941821.png)
name
和show
字段是可枚举(高亮)的嘛再看看通过ES6语法的class创建的实例对象:
可以只直观看出,
name
字段是可枚举(高亮)的,而show
是不可枚举(没高亮)的~The text was updated successfully, but these errors were encountered: