选择篇(011)-当我们这样做时会发生什么?
文章目录
function bark() {
console.log('Woof!')
}
bark.animal = 'dog'A: 正常运行!
B: SyntaxError. 你不能通过这种方式给函数增加属性。
C: undefined
D: ReferenceError
function bark() {
console.log('Woof!')
}
bark.animal = 'dog'A: 正常运行!
B: SyntaxError. 你不能通过这种方式给函数增加属性。
C: undefined
D: ReferenceError
评论
登录后参与技术讨论,分享你的经验与见解。
登录 / 注册暂无评论