摘要: javascript中的 get 与 set 下划线 get 语法: js function person(){ this._name = ""; } person.prototype = { get name(){ return this._name; }, set name(value){ // 阅读全文
posted @ 2018-08-15 11:35 Erwin's 阅读(104) 评论(0) 推荐(0)
摘要: 一直不是很清楚javascript的global到底表现在哪些方面,所以今天特地做了几个测试: var str = 'bbaaabb', reg = /^b|b$/; while(reg.test(str)){ str = str.replace(reg,''); console.log(reg.l 阅读全文
posted @ 2016-02-25 15:25 Erwin's 阅读(547) 评论(0) 推荐(0)